Fixed exception from EA
"The constraint shouldn't contain different type variables on both sides: T <: R". It occurred because we analyzed function literals before completion with unsubstituted (therefore wrong) expected type, and cached resulting type.
This commit is contained in:
@@ -3312,6 +3312,11 @@ public class JetDiagnosticsTestGenerated extends AbstractDiagnosticsTestWithEage
|
||||
JetTestUtils.assertAllTestsPresentByMetadata(this.getClass(), "org.jetbrains.jet.generators.tests.GenerateTests", new File("compiler/testData/diagnostics/tests/inference/constraints"), Pattern.compile("^(.+)\\.kt$"), true);
|
||||
}
|
||||
|
||||
@TestMetadata("constraintOnFunctionLiteral.kt")
|
||||
public void testConstraintOnFunctionLiteral() throws Exception {
|
||||
doTest("compiler/testData/diagnostics/tests/inference/constraints/constraintOnFunctionLiteral.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("equalityConstraintOnNullableType.kt")
|
||||
public void testEqualityConstraintOnNullableType() throws Exception {
|
||||
doTest("compiler/testData/diagnostics/tests/inference/constraints/equalityConstraintOnNullableType.kt");
|
||||
|
||||
Reference in New Issue
Block a user