Serialize descriptors for local/anonymous classes on JVM

Reflection needs this information to work for local classes and anonymous
objects
This commit is contained in:
Alexander Udalov
2015-02-14 03:27:05 +03:00
parent 98b554d995
commit 6ce8d6bd2e
34 changed files with 567 additions and 127 deletions
@@ -260,10 +260,13 @@ public abstract class FileBasedKotlinClass implements KotlinJvmBinaryClass {
return ClassId.topLevel(new FqName(name.replace('/', '.')));
}
// TODO: this is a hack which can be dropped once JVM back-end begins to write InnerClasses attribute for all referenced classes
if (name.equals(JvmAnnotationNames.KotlinSyntheticClass.KIND_INTERNAL_NAME)) {
// TODO: this is a hack which can be dropped once JVM back-end begins to write InnerClasses attribute for all referenced classes
return JvmAnnotationNames.KotlinSyntheticClass.KIND_CLASS_ID;
}
else if (name.equals(JvmAnnotationNames.KotlinClass.KIND_INTERNAL_NAME)) {
return JvmAnnotationNames.KotlinClass.KIND_CLASS_ID;
}
List<String> classes = new ArrayList<String>(1);
boolean local = false;