浏览代码

Enums won't have superclasses

kindlich 4 年前
父节点
当前提交
370c2af1e9
找不到此签名对应的密钥
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1
    1
      JavaIntegration/src/main/java/org/openzen/zencode/java/JavaNativeModule.java

+ 1
- 1
JavaIntegration/src/main/java/org/openzen/zencode/java/JavaNativeModule.java 查看文件

339
 			definition.setSuperType(loadType(context, cls.getAnnotatedSuperclass()).type);
339
 			definition.setSuperType(loadType(context, cls.getAnnotatedSuperclass()).type);
340
 		}
340
 		}
341
 
341
 
342
-		if (!foundRegistry && definition.getSuperType() == null && cls != Object.class) {
342
+		if (!foundRegistry && definition.getSuperType() == null && cls != Object.class && !(definition instanceof EnumDefinition)) {
343
 			definition.setSuperType(loadType(context, Object.class, false, false).type);
343
 			definition.setSuperType(loadType(context, Object.class, false, false).type);
344
 		}
344
 		}
345
 
345
 

正在加载...
取消
保存