Fix false warning about useless cast in property and property accessor
Note that there are some other problems, for example: `val a = if (true) 1 as Number else 2`, here we'll get useless cast #KT-9551 Fixed #KT-9645 Fixed
This commit is contained in:
@@ -2686,6 +2686,12 @@ public class DiagnosticsTestGenerated extends AbstractDiagnosticsTest {
|
||||
doTest(fileName);
|
||||
}
|
||||
|
||||
@TestMetadata("AsInPropertyAndPropertyAccessor.kt")
|
||||
public void testAsInPropertyAndPropertyAccessor() throws Exception {
|
||||
String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/diagnostics/tests/cast/AsInPropertyAndPropertyAccessor.kt");
|
||||
doTest(fileName);
|
||||
}
|
||||
|
||||
@TestMetadata("AsNothing.kt")
|
||||
public void testAsNothing() throws Exception {
|
||||
String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/diagnostics/tests/cast/AsNothing.kt");
|
||||
|
||||
Reference in New Issue
Block a user