ReadJavaBinaryClassTest: Any
This commit is contained in:
-1
@@ -187,7 +187,6 @@ public class JavaTypeTransformer {
|
||||
PrimitiveType primitiveType = jvmPrimitiveType.getPrimitiveType();
|
||||
classDescriptorMap.put(jvmPrimitiveType.getWrapper().getFqName(), standardLibrary.getPrimitiveClassDescriptor(primitiveType));
|
||||
}
|
||||
//classDescriptorMap.put("java.lang.Object", standardLibrary.get
|
||||
classDescriptorMap.put("java.lang.String", standardLibrary.getString());
|
||||
}
|
||||
return classDescriptorMap;
|
||||
|
||||
+4
@@ -74,6 +74,10 @@ public abstract class JetTypeJetSignatureReader extends JetSignatureExceptionsAd
|
||||
String ourName = name.replace('/', '.');
|
||||
|
||||
this.classDescriptor = this.javaSemanticServices.getTypeTransformer().getPrimitiveWrappersClassDescriptorMap().get(ourName);
|
||||
|
||||
if (this.classDescriptor == null && ourName.equals("java.lang.Object")) {
|
||||
this.classDescriptor = JetStandardClasses.getAny();
|
||||
}
|
||||
|
||||
if (this.classDescriptor == null) {
|
||||
this.classDescriptor = javaDescriptorResolver.resolveClass(ourName);
|
||||
|
||||
@@ -0,0 +1,3 @@
|
||||
package test
|
||||
|
||||
fun any(): Any = 1
|
||||
@@ -0,0 +1,3 @@
|
||||
package test
|
||||
|
||||
fun anyq(): Any? = 1
|
||||
@@ -0,0 +1,5 @@
|
||||
package test
|
||||
|
||||
import java.util.List
|
||||
|
||||
fun listOfAny(): List<Any> = throw Exception()
|
||||
@@ -0,0 +1,5 @@
|
||||
package test
|
||||
|
||||
import java.util.List
|
||||
|
||||
fun listOfAnyQ(): List<Any?> = throw Exception()
|
||||
Reference in New Issue
Block a user