[K2]: Missing error and miscompilation in destructuring declaration delegation
In convertDestructingDeclaration, property delegates are mistakenly treated as valid expressions for destructuring, but they should be ignored. #KT-65021 Fixed
This commit is contained in:
committed by
Space Team
parent
b0367d9399
commit
1d817e2ace
+16
@@ -11603,6 +11603,22 @@ public class FirLightTreeOldFrontendDiagnosticsTestGenerated extends AbstractFir
|
||||
}
|
||||
}
|
||||
|
||||
@Nested
|
||||
@TestMetadata("compiler/testData/diagnostics/tests/destructuring")
|
||||
@TestDataPath("$PROJECT_ROOT")
|
||||
public class Destructuring {
|
||||
@Test
|
||||
public void testAllFilesPresentInDestructuring() throws Exception {
|
||||
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/diagnostics/tests/destructuring"), Pattern.compile("^(.+)\\.kt$"), Pattern.compile("^(.+)\\.(reversed|fir|ll)\\.kts?$"), true, "multiplatform");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("delegationInDestructuring.kt")
|
||||
public void testDelegationInDestructuring() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/tests/destructuring/delegationInDestructuring.kt");
|
||||
}
|
||||
}
|
||||
|
||||
@Nested
|
||||
@TestMetadata("compiler/testData/diagnostics/tests/duplicateJvmSignature")
|
||||
@TestDataPath("$PROJECT_ROOT")
|
||||
|
||||
+16
@@ -11609,6 +11609,22 @@ public class FirPsiOldFrontendDiagnosticsTestGenerated extends AbstractFirPsiDia
|
||||
}
|
||||
}
|
||||
|
||||
@Nested
|
||||
@TestMetadata("compiler/testData/diagnostics/tests/destructuring")
|
||||
@TestDataPath("$PROJECT_ROOT")
|
||||
public class Destructuring {
|
||||
@Test
|
||||
public void testAllFilesPresentInDestructuring() throws Exception {
|
||||
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/diagnostics/tests/destructuring"), Pattern.compile("^(.*)\\.kts?$"), Pattern.compile("^(.+)\\.(reversed|fir|ll)\\.kts?$"), true, "multiplatform");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("delegationInDestructuring.kt")
|
||||
public void testDelegationInDestructuring() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/tests/destructuring/delegationInDestructuring.kt");
|
||||
}
|
||||
}
|
||||
|
||||
@Nested
|
||||
@TestMetadata("compiler/testData/diagnostics/tests/duplicateJvmSignature")
|
||||
@TestDataPath("$PROJECT_ROOT")
|
||||
|
||||
Reference in New Issue
Block a user