On Thu, 14 May 2026 09:11:15 GMT, Maurizio Cimadamore <[email protected]> 
wrote:

>> src/java.base/share/classes/java/lang/foreign/FunctionDescriptor.java line 
>> 46:
>> 
>>> 44:  * @implSpec
>>> 45:  * Implementing classes are immutable, thread-safe and
>>> 46:  * <a 
>>> href="{@docRoot}/java.base/java/lang/doc-files/ValueBased.html">value-based</a>.
>> 
>> Shouldn't this use the `@ValueBased` anno instead?
>
> (I know this is slightly outside the scope of the PR -- but since we're here 
> and the discussion is fresh...)

I agree with adding `@ValueBased` to `FunctionDescriptor`, and also I think the 
link to ValueBased.html can be kept.

According to discussion on #30444, the description does not seem to consist, 
and it will be considered about it in future. 
https://github.com/openjdk/jdk/pull/30444#discussion_r2999753567
Actually `Integer` has both the description and `@ValueBased` as following:


 * <p>This is a <a 
href="{@docRoot}/java.base/java/lang/doc-files/ValueBased.html">value-based</a>
 
  : <snip>

@jdk.internal.ValueBased
public final class Integer extends Number
        implements Comparable<Integer>, Constable, ConstantDesc {


If you agree, I add `@ValueBased` to `FunctionDescriptor` without description 
changes, and update CSR to follow it. What do you think?

-------------

PR Review Comment: https://git.openjdk.org/jdk/pull/30481#discussion_r3241059142

Reply via email to