RFR(S): JDK-8247938: Change various JVM enums like LinkInfo::AccessCheck and Klass::DefaultsLookupMode to enum class

Lois Foltan lois.foltan at oracle.com
Fri Jul 31 17:55:17 UTC 2020


Please review the webrev to change the following unscoped enumeration 
declarations to scoped enumerations.

Klass::DefaultsLookupMode
Klass::OverpassLookupMode
Klass::StaticLookupMode
Klass::PrivateLookupMode
LinkInfo::AccessCheck

With C++11/14 enum class provides the added type safety to prevent 0 
(integral) or false (boolean) to be implicitly converted to 
AccessCheck::needs_access_check for example.

open webrev 
at:http://cr.openjdk.java.net/~lfoltan/bug_jdk8247938.0/webrev/ 
<http://cr.openjdk.java.net/~lfoltan/bug_jdk8247938.0/webrev/index.html>
bug link: https://bugs.openjdk.java.net/browse/JDK-8247938

Testing: hs-tier1 & 2 complete, hs-tier3-6 in progress

Thanks,
Lois


More information about the hotspot-runtime-dev mailing list