[K2] Allow using simple boolean expressions in constant position

Such behavior is not the same as in K1, but it is more consistent.

#KT-64400 Fixed
This commit is contained in:
Ivan Kylchik
2023-12-05 16:58:44 +01:00
committed by Space Team
parent 38ea2ce973
commit f8e9e99d87
13 changed files with 129 additions and 40 deletions
@@ -23951,6 +23951,12 @@ public class DiagnosticCompilerTestFE10TestdataTestGenerated extends AbstractDia
runTest("compiler/testData/diagnostics/tests/modifiers/const/arrayInAnnotationArgumentType.kt");
}
@Test
@TestMetadata("compare.kt")
public void testCompare() throws Exception {
runTest("compiler/testData/diagnostics/tests/modifiers/const/compare.kt");
}
@Test
@TestMetadata("constInteraction.kt")
public void testConstInteraction() throws Exception {
@@ -23951,6 +23951,12 @@ public class LLFirPreresolvedReversedDiagnosticCompilerFE10TestDataTestGenerated
runTest("compiler/testData/diagnostics/tests/modifiers/const/arrayInAnnotationArgumentType.kt");
}
@Test
@TestMetadata("compare.kt")
public void testCompare() throws Exception {
runTest("compiler/testData/diagnostics/tests/modifiers/const/compare.kt");
}
@Test
@TestMetadata("constInteraction.kt")
public void testConstInteraction() throws Exception {