OpenJDK / zgc / zgc
changeset 52128:f036f767708e
8210434: [Graal] 8209301 prevents GitHub Graal from compiling with latest JDK
Reviewed-by: dnsimon, kvn
author | dlong |
---|---|
date | Mon, 10 Sep 2018 16:33:05 -0700 |
parents | b83571bbc147 |
children | fca6c9aca3e6 |
files | src/jdk.aot/share/classes/jdk.tools.jaotc/src/jdk/tools/jaotc/AOTCompiledClass.java src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotResolvedObjectType.java |
diffstat | 2 files changed, 16 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/src/jdk.aot/share/classes/jdk.tools.jaotc/src/jdk/tools/jaotc/AOTCompiledClass.java Mon Sep 10 19:18:04 2018 -0400 +++ b/src/jdk.aot/share/classes/jdk.tools.jaotc/src/jdk/tools/jaotc/AOTCompiledClass.java Mon Sep 10 16:33:05 2018 -0700 @@ -74,7 +74,7 @@ this.dependentMethods = new ArrayList<>(); this.classId = classId; this.type = type; - this.metadataName = type.isUnsafeAnonymous() ? "anon<" + classId + ">" : type.getName(); + this.metadataName = type.isAnonymous() ? "anon<" + classId + ">" : type.getName(); this.gotIndex = binaryContainer.addTwoSlotKlassSymbol(metadataName); this.compiledMethodsOffset = -1; // Not compiled classes do not have compiled methods. this.dependentMethodsOffset = -1;
--- a/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotResolvedObjectType.java Mon Sep 10 19:18:04 2018 -0400 +++ b/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotResolvedObjectType.java Mon Sep 10 16:33:05 2018 -0700 @@ -110,6 +110,21 @@ @Override ResolvedJavaMethod getClassInitializer(); + /** + * Checks whether this type is an unsafe anonymous class. + * + * @return {@code true} if this type is an unsafe anonymous class + */ boolean isUnsafeAnonymous(); + /** + * Checks whether this type is an unsafe anonymous class. + * This method is here to maintain compatibility with JDK11. + * + * @return {@code true} if this type is an unsafe anonymous class + */ + default boolean isAnonymous() { + return isUnsafeAnonymous(); + } + }