[JDK9] RFR 8167229: Improve VarHandle documentation

Paul Sandoz paul.sandoz at oracle.com
Thu Apr 27 21:26:50 UTC 2017


> On 27 Apr 2017, at 11:32, Martin Buchholz <martinrb at google.com> wrote:
> 
> Looks good!
> 

Thanks, i made the changes you propose in the previous emails.


> ---
> 
> Consider changing parameter name of findVarHandle name to make it clearer it's a field name
> name => fieldName
> findVarHandle(Class<?> recv, String name, Class<?> type)
> 

“name” is consistently used throughout, so i would prefer to keep as in and consider doing something more global if necessary. I don’t really have a strong opinion on this.


> I might have named these methods instanceFieldVarHandle and staticFieldVarHandle to make it clearer there are many kinds of VarHandle and ways of obtaining them.  But probably too late now.
> 

They are kept in sync with the method handle getter/setter equivalents.


> ---
> 
> it's => its
> 
> 1921          * {@code volatile} declaration) in accordance to it's specified
> 1922          * access modes.
> 

Done.

Pal.




More information about the core-libs-dev mailing list