Added @ExpectLoadErrors annotations to test data.
Also, fixed syntax error in AddNullabilitySameJavaType.
This commit is contained in:
+2
@@ -2,6 +2,7 @@ package test;
|
||||
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
import jet.runtime.typeinfo.KotlinSignature;
|
||||
import org.jetbrains.jet.jvm.compiler.annotation.ExpectLoadError;
|
||||
|
||||
public interface AddNullabilityJavaSubtype {
|
||||
|
||||
@@ -11,6 +12,7 @@ public interface AddNullabilityJavaSubtype {
|
||||
}
|
||||
|
||||
public interface Sub extends Super {
|
||||
@ExpectLoadError("Alternative signature has 2 syntax errors, first is at 10: Expecting '(")
|
||||
@KotlinSignature("fun String? foo()")
|
||||
String foo();
|
||||
}
|
||||
|
||||
+2
@@ -3,6 +3,7 @@ package test;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
import java.util.List;
|
||||
import jet.runtime.typeinfo.KotlinSignature;
|
||||
import org.jetbrains.jet.jvm.compiler.annotation.ExpectLoadError;
|
||||
|
||||
public interface AddNullabilitySameGenericType1 {
|
||||
|
||||
@@ -12,6 +13,7 @@ public interface AddNullabilitySameGenericType1 {
|
||||
}
|
||||
|
||||
public interface Sub extends Super {
|
||||
@ExpectLoadError("Auto type 'jet.String' is not-null, while type in alternative signature is nullable: 'String?'")
|
||||
@KotlinSignature("fun foo(): MutableList<String?>")
|
||||
List<String> foo();
|
||||
}
|
||||
|
||||
+2
@@ -3,6 +3,7 @@ package test;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
import java.util.List;
|
||||
import jet.runtime.typeinfo.KotlinSignature;
|
||||
import org.jetbrains.jet.jvm.compiler.annotation.ExpectLoadError;
|
||||
|
||||
public interface AddNullabilitySameGenericType2 {
|
||||
|
||||
@@ -12,6 +13,7 @@ public interface AddNullabilitySameGenericType2 {
|
||||
}
|
||||
|
||||
public interface Sub extends Super {
|
||||
@ExpectLoadError("Auto type 'jet.MutableList<jet.String>' is not-null, while type in alternative signature is nullable: 'MutableList<String>?'")
|
||||
@KotlinSignature("fun foo(): MutableList<String>?")
|
||||
List<String> foo();
|
||||
}
|
||||
|
||||
+3
-1
@@ -3,6 +3,7 @@ package test;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
import java.lang.CharSequence;
|
||||
import jet.runtime.typeinfo.KotlinSignature;
|
||||
import org.jetbrains.jet.jvm.compiler.annotation.ExpectLoadError;
|
||||
|
||||
public interface AddNullabilitySameJavaType {
|
||||
|
||||
@@ -12,7 +13,8 @@ public interface AddNullabilitySameJavaType {
|
||||
}
|
||||
|
||||
public interface Sub extends Super {
|
||||
@KotlinSignature("fun CharSequence? foo()")
|
||||
@ExpectLoadError("Auto type 'jet.CharSequence' is not-null, while type in alternative signature is nullable: 'CharSequence?'")
|
||||
@KotlinSignature("fun foo(): CharSequence?")
|
||||
CharSequence foo();
|
||||
}
|
||||
}
|
||||
+2
@@ -2,6 +2,7 @@ package test;
|
||||
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
import jet.runtime.typeinfo.KotlinSignature;
|
||||
import org.jetbrains.jet.jvm.compiler.annotation.ExpectLoadError;
|
||||
|
||||
import java.util.*;
|
||||
|
||||
@@ -18,6 +19,7 @@ public interface TwoSuperclassesConflictingProjectionKinds {
|
||||
}
|
||||
|
||||
public interface Sub extends Super1, Super2 {
|
||||
@ExpectLoadError("Incompatible projection kinds in type arguments of super methods' return types: [CharSequence, out CharSequence]")
|
||||
public Collection<CharSequence> foo();
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user