(XS) RFR JDK-8233956: MethodHandles.dropArguments javadoc lists parameters in wrong order
Mandy Chung
mandy.chung at oracle.com
Fri Nov 22 19:29:53 UTC 2019
Thanks for the prompt review.
Mandy
On 11/22/19 11:26 AM, Jonathan Gibbons wrote:
> Looks good to me.
>
> -- Jon
>
> On 11/22/19 11:17 AM, Mandy Chung wrote:
>> This patch reorders `@param pos` of MethodHandles.dropArguments
>> matching the method signature.
>>
>> It'd be nice if javadoc generates with the ordered list of @params
>> matching the method signature (I created JDK-8234682).
>>
>> diff --git
>> a/src/java.base/share/classes/java/lang/invoke/MethodHandles.java
>> b/src/java.base/share/classes/java/lang/invoke/MethodHandles.java
>> --- a/src/java.base/share/classes/java/lang/invoke/MethodHandles.java
>> +++ b/src/java.base/share/classes/java/lang/invoke/MethodHandles.java
>> @@ -4286,8 +4286,8 @@
>> * {@link #dropArguments(MethodHandle,int,Class...)
>> dropArguments}{@code (target, pos, valueTypes.toArray(new Class[0]))}
>> * </pre></blockquote>
>> * @param target the method handle to invoke after the arguments
>> are dropped
>> + * @param pos position of first argument to drop (zero for the
>> leftmost)
>> * @param valueTypes the type(s) of the argument(s) to drop
>> - * @param pos position of first argument to drop (zero for the
>> leftmost)
>> * @return a method handle which drops arguments of the given
>> types,
>> * before calling the original method handle
>> * @throws NullPointerException if the target is null,
>> @@ -4366,8 +4366,8 @@
>> * {@link #dropArguments(MethodHandle,int,List)
>> dropArguments}{@code (target, pos, Arrays.asList(valueTypes))}
>> * </pre></blockquote>
>> * @param target the method handle to invoke after the arguments
>> are dropped
>> + * @param pos position of first argument to drop (zero for the
>> leftmost)
>> * @param valueTypes the type(s) of the argument(s) to drop
>> - * @param pos position of first argument to drop (zero for the
>> leftmost)
>> * @return a method handle which drops arguments of the given
>> types,
>> * before calling the original method handle
>> * @throws NullPointerException if the target is null,
>>
>> Mandy
More information about the core-libs-dev
mailing list