Fix unsound smartcast from loop condition on assigned vars
^KT-22379 Fixed
This commit is contained in:
committed by
Dmitry Savvinov
parent
a7d706f693
commit
447c127036
@@ -19822,6 +19822,16 @@ public class DiagnosticsTestGenerated extends AbstractDiagnosticsTest {
|
||||
public void testWhileTrueWithBreakInIfCondition() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/tests/smartCasts/loops/WhileTrueWithBreakInIfCondition.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("whileWithAssertInConditionAndBreakAfter.kt")
|
||||
public void testWhileWithAssertInConditionAndBreakAfter() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/tests/smartCasts/loops/whileWithAssertInConditionAndBreakAfter.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("whileWithAssertInConditionAndBreakBefore.kt")
|
||||
public void testWhileWithAssertInConditionAndBreakBefore() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/tests/smartCasts/loops/whileWithAssertInConditionAndBreakBefore.kt");
|
||||
}
|
||||
}
|
||||
|
||||
@TestMetadata("compiler/testData/diagnostics/tests/smartCasts/objectLiterals")
|
||||
|
||||
Generated
+10
@@ -19822,6 +19822,16 @@ public class DiagnosticsUsingJavacTestGenerated extends AbstractDiagnosticsUsing
|
||||
public void testWhileTrueWithBreakInIfCondition() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/tests/smartCasts/loops/WhileTrueWithBreakInIfCondition.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("whileWithAssertInConditionAndBreakAfter.kt")
|
||||
public void testWhileWithAssertInConditionAndBreakAfter() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/tests/smartCasts/loops/whileWithAssertInConditionAndBreakAfter.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("whileWithAssertInConditionAndBreakBefore.kt")
|
||||
public void testWhileWithAssertInConditionAndBreakBefore() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/tests/smartCasts/loops/whileWithAssertInConditionAndBreakBefore.kt");
|
||||
}
|
||||
}
|
||||
|
||||
@TestMetadata("compiler/testData/diagnostics/tests/smartCasts/objectLiterals")
|
||||
|
||||
Reference in New Issue
Block a user