Don't report unused variable warning for delegated variables with provide delegate

^KT-38871 Fixed
This commit is contained in:
Mikhail Zarechenskiy
2023-03-27 11:20:33 +02:00
committed by Space Team
parent 18cfc9fcf1
commit 681e85eaed
9 changed files with 142 additions and 2 deletions
@@ -621,6 +621,12 @@ public class FirLightTreeOldFrontendDiagnosticsTestGenerated extends AbstractFir
runTest("compiler/testData/diagnostics/tests/noSymbolProvidersDuplicationInDiamond.kt");
}
@Test
@TestMetadata("noUnusedOnDelegationWithProvider.kt")
public void testNoUnusedOnDelegationWithProvider() throws Exception {
runTest("compiler/testData/diagnostics/tests/noUnusedOnDelegationWithProvider.kt");
}
@Test
@TestMetadata("Nullability.kt")
public void testNullability() throws Exception {
@@ -1143,6 +1149,12 @@ public class FirLightTreeOldFrontendDiagnosticsTestGenerated extends AbstractFir
runTest("compiler/testData/diagnostics/tests/UnusedParameters.kt");
}
@Test
@TestMetadata("unusedVariableOnRegularDelegatedProperty.kt")
public void testUnusedVariableOnRegularDelegatedProperty() throws Exception {
runTest("compiler/testData/diagnostics/tests/unusedVariableOnRegularDelegatedProperty.kt");
}
@Test
@TestMetadata("UnusedVariables.kt")
public void testUnusedVariables() throws Exception {
@@ -621,6 +621,12 @@ public class FirPsiOldFrontendDiagnosticsTestGenerated extends AbstractFirPsiDia
runTest("compiler/testData/diagnostics/tests/noSymbolProvidersDuplicationInDiamond.kt");
}
@Test
@TestMetadata("noUnusedOnDelegationWithProvider.kt")
public void testNoUnusedOnDelegationWithProvider() throws Exception {
runTest("compiler/testData/diagnostics/tests/noUnusedOnDelegationWithProvider.kt");
}
@Test
@TestMetadata("Nullability.kt")
public void testNullability() throws Exception {
@@ -1143,6 +1149,12 @@ public class FirPsiOldFrontendDiagnosticsTestGenerated extends AbstractFirPsiDia
runTest("compiler/testData/diagnostics/tests/UnusedParameters.kt");
}
@Test
@TestMetadata("unusedVariableOnRegularDelegatedProperty.kt")
public void testUnusedVariableOnRegularDelegatedProperty() throws Exception {
runTest("compiler/testData/diagnostics/tests/unusedVariableOnRegularDelegatedProperty.kt");
}
@Test
@TestMetadata("UnusedVariables.kt")
public void testUnusedVariables() throws Exception {