Review Request: JDK-8207146: Rename jdk.internal.misc.Unsafe::xxxObject to xxxReference

David Holmes david.holmes at oracle.com
Wed Oct 17 03:33:19 UTC 2018


Hi Mandy,

I took a look through all of this and it seems okay - though it was a 
little surprising how far the name change needed to spread.

Thanks,
David

On 17/10/2018 2:08 AM, Mandy Chung wrote:
> Webrev:
> http://cr.openjdk.java.net/~mchung/jdk12/webrevs/8207146/webrev.00/
> 
> Unsafe::getObject returns a reference to an object. Similarly
> Unsafe::putObject sets a reference in the given base+offset.
> This patch proposes to rename Unsafe xxxObject to xxxReference
> that will make the xxxReference API very clear that these
> are getters/setters for a reference (instance of object class)
> and ready for adding xxxValue in the futurefor values.
> Note that this renaming only applies to jdk.internal.misc.Unsafe
> but not sun.misc.Unsafe.  So no impact to existing libraries
> that depends on sun.misc.Unsafe in jdk.unsupported module.
> 
> I ran jdk_core, core_tools, langtools and nashorn tier1-3,
> hotspot_runtime, hotspot_compiler test groups.
> 
> thanks
> Mandy


More information about the core-libs-dev mailing list