diff --git a/compiler/testData/diagnostics/firTestWithJvmBackend/exceptionFromInterpreter_ir.fir.diag.txt b/compiler/testData/diagnostics/firTestWithJvmBackend/exceptionFromInterpreter_ir.fir.diag.txt new file mode 100644 index 00000000000..61f1296dac3 --- /dev/null +++ b/compiler/testData/diagnostics/firTestWithJvmBackend/exceptionFromInterpreter_ir.fir.diag.txt @@ -0,0 +1,7 @@ +/exceptionFromInterpreter_ir.kt:(174,179): warning: Division by zero + +/exceptionFromInterpreter_ir.kt:(205,210): warning: Division by zero + +/exceptionFromInterpreter_ir.kt:(243,264): error: Const 'val' initializer should be a constant value + +/exceptionFromInterpreter_ir.kt:(313,318): warning: Division by zero diff --git a/compiler/testData/diagnostics/tests/imports/EnumEntryVsStaticAmbiguity.fir.diag.txt b/compiler/testData/diagnostics/tests/imports/EnumEntryVsStaticAmbiguity.fir.diag.txt new file mode 100644 index 00000000000..20ab8172afb --- /dev/null +++ b/compiler/testData/diagnostics/tests/imports/EnumEntryVsStaticAmbiguity.fir.diag.txt @@ -0,0 +1 @@ +/test.kt:(154,158): error: Overload resolution ambiguity between candidates: [static field SOME: String = String(Some), static enum entry SOME: SomeEnum] diff --git a/compiler/testData/diagnostics/tests/imports/EnumEntryVsStaticAmbiguity3.fir.diag.txt b/compiler/testData/diagnostics/tests/imports/EnumEntryVsStaticAmbiguity3.fir.diag.txt new file mode 100644 index 00000000000..c5e8638141e --- /dev/null +++ b/compiler/testData/diagnostics/tests/imports/EnumEntryVsStaticAmbiguity3.fir.diag.txt @@ -0,0 +1 @@ +/test.kt:(160,164): error: Overload resolution ambiguity between candidates: [static field SOME: String = String(Some), static enum entry SOME: SomeEnum] diff --git a/compiler/testData/diagnostics/tests/inference/builderInference/kt47986Default.fir.diag.txt b/compiler/testData/diagnostics/tests/inference/builderInference/kt47986Default.fir.diag.txt new file mode 100644 index 00000000000..07cfb9e4816 --- /dev/null +++ b/compiler/testData/diagnostics/tests/inference/builderInference/kt47986Default.fir.diag.txt @@ -0,0 +1 @@ +/kt47986Default.fir.kt:(175,183): error: Not enough information to infer type variable K diff --git a/compiler/testData/diagnostics/tests/inference/builderInference/kt47986Disabled.fir.diag.txt b/compiler/testData/diagnostics/tests/inference/builderInference/kt47986Disabled.fir.diag.txt new file mode 100644 index 00000000000..a42a635b780 --- /dev/null +++ b/compiler/testData/diagnostics/tests/inference/builderInference/kt47986Disabled.fir.diag.txt @@ -0,0 +1 @@ +/kt47986Disabled.fir.kt:(249,257): error: Not enough information to infer type variable K diff --git a/compiler/testData/diagnostics/tests/inference/builderInference/kt47986_2.fir.diag.txt b/compiler/testData/diagnostics/tests/inference/builderInference/kt47986_2.fir.diag.txt new file mode 100644 index 00000000000..e4bfa407397 --- /dev/null +++ b/compiler/testData/diagnostics/tests/inference/builderInference/kt47986_2.fir.diag.txt @@ -0,0 +1 @@ +/kt47986_2.fir.kt:(187,195): error: Not enough information to infer type variable K diff --git a/compiler/testData/diagnostics/tests/inference/builderInference/kt47986_3.fir.diag.txt b/compiler/testData/diagnostics/tests/inference/builderInference/kt47986_3.fir.diag.txt new file mode 100644 index 00000000000..29ebb6107a5 --- /dev/null +++ b/compiler/testData/diagnostics/tests/inference/builderInference/kt47986_3.fir.diag.txt @@ -0,0 +1 @@ +/kt47986_3.fir.kt:(181,189): error: Not enough information to infer type variable K diff --git a/compiler/testData/diagnostics/tests/inference/builderInference/kt51464.fir.diag.txt b/compiler/testData/diagnostics/tests/inference/builderInference/kt51464.fir.diag.txt new file mode 100644 index 00000000000..9ab51535112 --- /dev/null +++ b/compiler/testData/diagnostics/tests/inference/builderInference/kt51464.fir.diag.txt @@ -0,0 +1 @@ +/kt51464.fir.kt:(298,307): error: Not enough information to infer type variable R diff --git a/compiler/testData/diagnostics/tests/inference/emptyIntersectionTypes/kt45461.fir.diag.txt b/compiler/testData/diagnostics/tests/inference/emptyIntersectionTypes/kt45461.fir.diag.txt new file mode 100644 index 00000000000..b9140e0e2f8 --- /dev/null +++ b/compiler/testData/diagnostics/tests/inference/emptyIntersectionTypes/kt45461.fir.diag.txt @@ -0,0 +1 @@ +/kt45461.kt:(245,252): warning: Type argument for a type parameter S can't be inferred because it has incompatible upper bounds: kotlin/String, kotlin/Int (multiple incompatible classes). This will become an error in a future release diff --git a/compiler/testData/diagnostics/tests/inference/emptyIntersectionTypes/kt45461_12.fir.diag.txt b/compiler/testData/diagnostics/tests/inference/emptyIntersectionTypes/kt45461_12.fir.diag.txt new file mode 100644 index 00000000000..1711be912a1 --- /dev/null +++ b/compiler/testData/diagnostics/tests/inference/emptyIntersectionTypes/kt45461_12.fir.diag.txt @@ -0,0 +1 @@ +/kt45461_12.kt:(296,303): warning: Type argument for a type parameter S can't be inferred because it has incompatible upper bounds: kotlin/String, K (multiple incompatible classes: kotlin/String, kotlin/Number). This will become an error in a future release diff --git a/compiler/testData/diagnostics/tests/inference/emptyIntersectionTypes/kt45461_2.fir.diag.txt b/compiler/testData/diagnostics/tests/inference/emptyIntersectionTypes/kt45461_2.fir.diag.txt new file mode 100644 index 00000000000..38b45e4f767 --- /dev/null +++ b/compiler/testData/diagnostics/tests/inference/emptyIntersectionTypes/kt45461_2.fir.diag.txt @@ -0,0 +1,3 @@ +/kt45461_2.kt:(253,260): warning: Type argument for a type parameter S can't be inferred because it has incompatible upper bounds: kotlin/String, K (multiple incompatible classes: kotlin/String, kotlin/Int). This will become an error in a future release + +/kt45461_2.kt:(198,201): warning: 'kotlin/Int' is a final type, and thus a value of the type parameter is predetermined diff --git a/compiler/testData/diagnostics/tests/inference/emptyIntersectionTypes/kt45461_25.fir.diag.txt b/compiler/testData/diagnostics/tests/inference/emptyIntersectionTypes/kt45461_25.fir.diag.txt new file mode 100644 index 00000000000..68eecabc4c6 --- /dev/null +++ b/compiler/testData/diagnostics/tests/inference/emptyIntersectionTypes/kt45461_25.fir.diag.txt @@ -0,0 +1,5 @@ +/kt45461_25.fir.kt:(176,180): warning: Unchecked cast: kotlin/Nothing? to S + +/kt45461_25.fir.kt:(276,283): error: Type argument for a type parameter S can't be inferred because it has incompatible upper bounds: kotlin/String, K (multiple incompatible classes: kotlin/String, kotlin/Int) + +/kt45461_25.fir.kt:(206,209): warning: 'kotlin/Int' is a final type, and thus a value of the type parameter is predetermined diff --git a/compiler/testData/diagnostics/tests/inference/emptyIntersectionTypes/kt45461_26.fir.diag.txt b/compiler/testData/diagnostics/tests/inference/emptyIntersectionTypes/kt45461_26.fir.diag.txt new file mode 100644 index 00000000000..c56d056930b --- /dev/null +++ b/compiler/testData/diagnostics/tests/inference/emptyIntersectionTypes/kt45461_26.fir.diag.txt @@ -0,0 +1,3 @@ +/kt45461_26.fir.kt:(176,180): warning: Unchecked cast: kotlin/Nothing? to S + +/kt45461_26.fir.kt:(224,232): warning: 'Out' is a final type, and thus a value of the type parameter is predetermined diff --git a/compiler/testData/diagnostics/tests/inference/emptyIntersectionTypes/kt45461_5.fir.diag.txt b/compiler/testData/diagnostics/tests/inference/emptyIntersectionTypes/kt45461_5.fir.diag.txt new file mode 100644 index 00000000000..b17b7f65bd8 --- /dev/null +++ b/compiler/testData/diagnostics/tests/inference/emptyIntersectionTypes/kt45461_5.fir.diag.txt @@ -0,0 +1 @@ +/kt45461_5.kt:(269,276): warning: Type argument for a type parameter S can't be inferred because it has incompatible upper bounds: kotlin/String, K (multiple incompatible classes: kotlin/String, kotlin/Number). This will become an error in a future release diff --git a/compiler/testData/diagnostics/tests/inference/emptyIntersectionTypes/kt48765.fir.diag.txt b/compiler/testData/diagnostics/tests/inference/emptyIntersectionTypes/kt48765.fir.diag.txt new file mode 100644 index 00000000000..0ebb167bbf7 --- /dev/null +++ b/compiler/testData/diagnostics/tests/inference/emptyIntersectionTypes/kt48765.fir.diag.txt @@ -0,0 +1,5 @@ +/kt48765.kt:(282,285): warning: Type argument for a type parameter T can't be inferred because it has incompatible upper bounds: kotlin/String, kotlin/Number (multiple incompatible classes). This will become an error in a future release + +/kt48765.kt:(379,383): warning: Unchecked cast: kotlin/String to T + +/kt48765.kt:(345,351): warning: 'kotlin/String' is a final type, and thus a value of the type parameter is predetermined diff --git a/compiler/testData/diagnostics/tests/inference/emptyIntersectionTypes/kt48935.fir.diag.txt b/compiler/testData/diagnostics/tests/inference/emptyIntersectionTypes/kt48935.fir.diag.txt new file mode 100644 index 00000000000..ef3dec047e1 --- /dev/null +++ b/compiler/testData/diagnostics/tests/inference/emptyIntersectionTypes/kt48935.fir.diag.txt @@ -0,0 +1 @@ +/kt48935.kt:(240,262): warning: Type argument for a type parameter T has possible incompatible upper bounds: Base, DoesNotImplementBase (final class and interface) diff --git a/compiler/testData/diagnostics/tests/inference/emptyIntersectionTypes/kt49661.fir.diag.txt b/compiler/testData/diagnostics/tests/inference/emptyIntersectionTypes/kt49661.fir.diag.txt new file mode 100644 index 00000000000..8acc734cf39 --- /dev/null +++ b/compiler/testData/diagnostics/tests/inference/emptyIntersectionTypes/kt49661.fir.diag.txt @@ -0,0 +1 @@ +/kt49661.kt:(251,252): warning: Type argument for a type parameter T can't be inferred because it has incompatible upper bounds: Foo, kotlin/Int (multiple incompatible classes). This will become an error in a future release diff --git a/compiler/testData/diagnostics/tests/inference/emptyIntersectionTypes/selectFromCovariantAndContravariantTypes.fir.diag.txt b/compiler/testData/diagnostics/tests/inference/emptyIntersectionTypes/selectFromCovariantAndContravariantTypes.fir.diag.txt new file mode 100644 index 00000000000..1f76e86a5af --- /dev/null +++ b/compiler/testData/diagnostics/tests/inference/emptyIntersectionTypes/selectFromCovariantAndContravariantTypes.fir.diag.txt @@ -0,0 +1 @@ +/selectFromCovariantAndContravariantTypes.kt:(335,344): warning: Type argument for a type parameter V can't be inferred because it has incompatible upper bounds: A, B (multiple incompatible classes). This will become an error in a future release diff --git a/compiler/testData/diagnostics/tests/j+k/types/notNullTypeParameterWithKotlinNullableWarnings.fir.diag.txt b/compiler/testData/diagnostics/tests/j+k/types/notNullTypeParameterWithKotlinNullableWarnings.fir.diag.txt new file mode 100644 index 00000000000..e89543cf64d --- /dev/null +++ b/compiler/testData/diagnostics/tests/j+k/types/notNullTypeParameterWithKotlinNullableWarnings.fir.diag.txt @@ -0,0 +1,3 @@ +/main.kt:(98,103): error: Argument type mismatch: actual type is V but @EnhancedNullability V & Any was expected + +/main.kt:(119,120): error: Argument type mismatch: actual type is kotlin/collections/List but ft<@EnhancedNullability kotlin/collections/MutableList<@EnhancedNullability V & Any>, @EnhancedNullability kotlin/collections/List<@EnhancedNullability V & Any>> was expected diff --git a/compiler/testData/diagnostics/tests/j+k/types/notNullTypeParameterWithKotlinOverridesDefinitelyNonNullable.fir.diag.txt b/compiler/testData/diagnostics/tests/j+k/types/notNullTypeParameterWithKotlinOverridesDefinitelyNonNullable.fir.diag.txt new file mode 100644 index 00000000000..788db7807c8 --- /dev/null +++ b/compiler/testData/diagnostics/tests/j+k/types/notNullTypeParameterWithKotlinOverridesDefinitelyNonNullable.fir.diag.txt @@ -0,0 +1,3 @@ +/main.kt:(72,80): error: 'takeV' overrides nothing + +/main.kt:(137,145): error: 'takeVList' overrides nothing diff --git a/compiler/testData/diagnostics/tests/smartCasts/smartCastOnAlienPropertyFromInvisibleClass.fir.diag.txt b/compiler/testData/diagnostics/tests/smartCasts/smartCastOnAlienPropertyFromInvisibleClass.fir.diag.txt new file mode 100644 index 00000000000..b565c5a09dc --- /dev/null +++ b/compiler/testData/diagnostics/tests/smartCasts/smartCastOnAlienPropertyFromInvisibleClass.fir.diag.txt @@ -0,0 +1,3 @@ +/B.kt:(133,134): error: Smart cast to 'kotlin/String' is impossible, because 'this@R|/Derived|.R|/Base.x|' is a public API property declared in different module + +/B.kt:(265,268): error: Smart cast to 'kotlin/String' is impossible, because 'R|/i|.R|/Base.x|' is a public API property declared in different module diff --git a/compiler/testData/diagnostics/testsWithStdLib/labelClashes.fir.diag.txt b/compiler/testData/diagnostics/testsWithStdLib/labelClashes.fir.diag.txt new file mode 100644 index 00000000000..4e8edb536b5 --- /dev/null +++ b/compiler/testData/diagnostics/testsWithStdLib/labelClashes.fir.diag.txt @@ -0,0 +1,7 @@ +/labelClashes.fir.kt:(84,87): error: Unresolved reference: inc + +/labelClashes.fir.kt:(151,154): error: Unresolved reference: inc + +/labelClashes.fir.kt:(268,271): error: Unresolved reference: foo + +/labelClashes.fir.kt:(331,334): error: Unresolved reference: foo diff --git a/compiler/testData/diagnostics/testsWithStdLib/typealias/upperBoundViolated2.fir.diag.txt b/compiler/testData/diagnostics/testsWithStdLib/typealias/upperBoundViolated2.fir.diag.txt new file mode 100644 index 00000000000..601ddb7c844 --- /dev/null +++ b/compiler/testData/diagnostics/testsWithStdLib/typealias/upperBoundViolated2.fir.diag.txt @@ -0,0 +1 @@ +/upperBoundViolated2.fir.kt:(111,123): error: Type argument is not within its bounds: should be subtype of 'kotlin/collections/List' diff --git a/compiler/tests-common-new/tests/org/jetbrains/kotlin/test/frontend/fir/handlers/FirDiagnosticsHandler.kt b/compiler/tests-common-new/tests/org/jetbrains/kotlin/test/frontend/fir/handlers/FirDiagnosticsHandler.kt index 9c0ca5ed42e..65c312d72e1 100644 --- a/compiler/tests-common-new/tests/org/jetbrains/kotlin/test/frontend/fir/handlers/FirDiagnosticsHandler.kt +++ b/compiler/tests-common-new/tests/org/jetbrains/kotlin/test/frontend/fir/handlers/FirDiagnosticsHandler.kt @@ -10,8 +10,10 @@ import org.jetbrains.kotlin.* import org.jetbrains.kotlin.checkers.diagnostics.factories.DebugInfoDiagnosticFactory0 import org.jetbrains.kotlin.checkers.diagnostics.factories.DebugInfoDiagnosticFactory1 import org.jetbrains.kotlin.checkers.utils.TypeOfCall +import org.jetbrains.kotlin.cli.common.messages.AnalyzerWithCompilerReport import org.jetbrains.kotlin.diagnostics.* import org.jetbrains.kotlin.diagnostics.rendering.Renderers +import org.jetbrains.kotlin.diagnostics.rendering.RootDiagnosticRendererFactory import org.jetbrains.kotlin.fir.* import org.jetbrains.kotlin.fir.analysis.diagnostics.FirErrors import org.jetbrains.kotlin.fir.builder.FirSyntaxErrors @@ -48,7 +50,9 @@ import org.jetbrains.kotlin.test.model.TestModule import org.jetbrains.kotlin.test.runners.lightTreeSyntaxDiagnosticsReporterHolder import org.jetbrains.kotlin.test.services.* import org.jetbrains.kotlin.test.utils.AbstractTwoAttributesMetaInfoProcessor +import org.jetbrains.kotlin.test.utils.MultiModuleInfoDumper import org.jetbrains.kotlin.util.OperatorNameConventions +import org.jetbrains.kotlin.util.capitalizeDecapitalize.toLowerCaseAsciiOnly @OptIn(SymbolInternals::class) class FirDiagnosticsHandler(testServices: TestServices) : FirAnalysisHandler(testServices) { @@ -64,6 +68,16 @@ class FirDiagnosticsHandler(testServices: TestServices) : FirAnalysisHandler(tes override val additionalServices: List = listOf(service(::DiagnosticsService)) + private val dumper: MultiModuleInfoDumper = MultiModuleInfoDumper(moduleHeaderTemplate = "// -- Module: <%s> --") + + override fun processAfterAllModules(someAssertionWasFailed: Boolean) { + if (dumper.isEmpty()) return + val resultDump = dumper.generateResultingDump() + val testDataFile = testServices.moduleStructure.originalTestDataFiles.first() + val expectedFile = testDataFile.parentFile.resolve("${testDataFile.nameWithoutFirExtension}.fir.diag.txt") + assertions.assertEqualsToFile(expectedFile, resultDump) + } + override fun processModule(module: TestModule, info: FirOutputArtifact) { for (part in info.partsForDependsOnModules) { val diagnosticsPerFile = part.firAnalyzerFacade.runCheckers() @@ -92,6 +106,7 @@ class FirDiagnosticsHandler(testServices: TestServices) : FirAnalysisHandler(tes globalMetadataInfoHandler.addMetadataInfosForFile(file, diagnosticsMetadataInfos) collectSyntaxDiagnostics(currentModule, file, firFile, lightTreeEnabled, lightTreeComparingModeEnabled, forceRenderArguments) collectDebugInfoDiagnostics(currentModule, file, firFile, lightTreeEnabled, lightTreeComparingModeEnabled) + checkFullDiagnosticRender(module, diagnostics, file) } } } @@ -323,7 +338,18 @@ class FirDiagnosticsHandler(testServices: TestServices) : FirAnalysisHandler(tes else -> null } - override fun processAfterAllModules(someAssertionWasFailed: Boolean) {} + private fun checkFullDiagnosticRender(module: TestModule, diagnostics: List, file: TestFile) { + if (DiagnosticsDirectives.RENDER_DIAGNOSTICS_FULL_TEXT !in module.directives) return + if (diagnostics.isEmpty()) return + + val reportedDiagnostics = diagnostics.map { + val severity = AnalyzerWithCompilerReport.convertSeverity(it.severity).toString().toLowerCaseAsciiOnly() + val message = RootDiagnosticRendererFactory(it).render(it) + "/${file.name}:${it.textRanges.first()}: $severity: $message" + } + + dumper.builderForModule(module).appendLine(reportedDiagnostics.joinToString(separator = "\n\n")) + } } fun List.diagnosticCodeMetaInfos( diff --git a/plugins/assign-plugin/testData/diagnostics/incorrectUsage.fir.diag.txt b/plugins/assign-plugin/testData/diagnostics/incorrectUsage.fir.diag.txt new file mode 100644 index 00000000000..42cbc4e86ea --- /dev/null +++ b/plugins/assign-plugin/testData/diagnostics/incorrectUsage.fir.diag.txt @@ -0,0 +1,7 @@ +/incorrectUsage.fir.kt:(396,397): error: + +/incorrectUsage.fir.kt:(390,395): error: None of the following functions are applicable: [fun assign(v: String): Unit, fun assign(v: StringProperty): Unit] + +/incorrectUsage.fir.kt:(542,543): error: + +/incorrectUsage.fir.kt:(536,541): error: None of the following functions are applicable: [fun assign(v: String): Unit, fun assign(v: StringProperty): Unit] diff --git a/plugins/assign-plugin/testData/diagnostics/localVariables.fir.diag.txt b/plugins/assign-plugin/testData/diagnostics/localVariables.fir.diag.txt new file mode 100644 index 00000000000..0ffddf2be26 --- /dev/null +++ b/plugins/assign-plugin/testData/diagnostics/localVariables.fir.diag.txt @@ -0,0 +1,13 @@ +/localVariables.fir.kt:(401,409): error: Val cannot be reassigned + +/localVariables.fir.kt:(412,418): error: Assignment type mismatch: actual type is kotlin/String but StringProperty was expected + +/localVariables.fir.kt:(521,529): error: Val cannot be reassigned + +/localVariables.fir.kt:(673,679): error: Assignment type mismatch: actual type is kotlin/String but StringProperty was expected + +/localVariables.fir.kt:(917,925): error: Val cannot be reassigned + +/localVariables.fir.kt:(928,934): error: Assignment type mismatch: actual type is kotlin/String but StringProperty was expected + +/localVariables.fir.kt:(995,1003): error: Val cannot be reassigned diff --git a/plugins/assign-plugin/testData/diagnostics/methodDeclaration.fir.diag.txt b/plugins/assign-plugin/testData/diagnostics/methodDeclaration.fir.diag.txt new file mode 100644 index 00000000000..f75f3e45151 --- /dev/null +++ b/plugins/assign-plugin/testData/diagnostics/methodDeclaration.fir.diag.txt @@ -0,0 +1,13 @@ +/methodDeclaration.fir.kt:(119,125): error: + +/methodDeclaration.fir.kt:(206,212): error: + +/methodDeclaration.fir.kt:(328,334): error: + +/methodDeclaration.fir.kt:(572,573): error: + +/methodDeclaration.fir.kt:(594,595): error: + +/methodDeclaration.fir.kt:(870,875): error: Val cannot be reassigned + +/methodDeclaration.fir.kt:(878,880): error: Assignment type mismatch: actual type is kotlin/Int but IntProperty was expected diff --git a/plugins/assign-plugin/testData/diagnostics/noAnnotation.fir.diag.txt b/plugins/assign-plugin/testData/diagnostics/noAnnotation.fir.diag.txt new file mode 100644 index 00000000000..318c12543ad --- /dev/null +++ b/plugins/assign-plugin/testData/diagnostics/noAnnotation.fir.diag.txt @@ -0,0 +1,19 @@ +/noAnnotation.fir.kt:(424,429): error: Val cannot be reassigned + +/noAnnotation.fir.kt:(432,436): error: Assignment type mismatch: actual type is kotlin/String but StringProperty was expected + +/noAnnotation.fir.kt:(446,451): error: Val cannot be reassigned + +/noAnnotation.fir.kt:(500,505): error: Val cannot be reassigned + +/noAnnotation.fir.kt:(508,512): error: Assignment type mismatch: actual type is kotlin/String but StringProperty was expected + +/noAnnotation.fir.kt:(544,549): error: Val cannot be reassigned + +/noAnnotation.fir.kt:(588,593): error: Val cannot be reassigned + +/noAnnotation.fir.kt:(596,598): error: Assignment type mismatch: actual type is kotlin/Int but StringProperty was expected + +/noAnnotation.fir.kt:(624,629): error: Val cannot be reassigned + +/noAnnotation.fir.kt:(632,634): error: Assignment type mismatch: actual type is kotlin/Int but StringProperty was expected diff --git a/plugins/assign-plugin/testData/diagnostics/otherOperators.fir.diag.txt b/plugins/assign-plugin/testData/diagnostics/otherOperators.fir.diag.txt new file mode 100644 index 00000000000..f7f05d67786 --- /dev/null +++ b/plugins/assign-plugin/testData/diagnostics/otherOperators.fir.diag.txt @@ -0,0 +1,37 @@ +/otherOperators.fir.kt:(456,458): error: Unresolved reference: plusAssign + +/otherOperators.fir.kt:(502,504): error: Unresolved reference: plusAssign + +/otherOperators.fir.kt:(560,562): error: Unresolved reference: compareTo + +/otherOperators.fir.kt:(606,608): error: Unresolved reference: compareTo + +/otherOperators.fir.kt:(664,666): error: Unresolved reference: compareTo + +/otherOperators.fir.kt:(710,712): error: Unresolved reference: compareTo + +/otherOperators.fir.kt:(769,772): error: No set method providing array access + +/otherOperators.fir.kt:(817,820): error: No set method providing array access + +/otherOperators.fir.kt:(882,888): error: No set method providing array access + +/otherOperators.fir.kt:(933,939): error: No set method providing array access + +/otherOperators.fir.kt:(1003,1012): error: No set method providing array access + +/otherOperators.fir.kt:(1057,1066): error: No set method providing array access + +/otherOperators.fir.kt:(1131,1133): error: Unresolved reference: += + +/otherOperators.fir.kt:(1180,1182): error: Unresolved reference: += + +/otherOperators.fir.kt:(1325,1328): error: No set method providing array access + +/otherOperators.fir.kt:(1431,1437): error: Variable expected + +/otherOperators.fir.kt:(1477,1483): error: Variable expected + +/otherOperators.fir.kt:(1128,1129): error: Too many arguments for public final fun /StringProperty.get(): R|kotlin/String| + +/otherOperators.fir.kt:(1177,1178): error: Too many arguments for public final fun /StringProperty.get(): R|kotlin/String| diff --git a/plugins/assign-plugin/testData/diagnostics/plusAssignPrecedence.fir.diag.txt b/plugins/assign-plugin/testData/diagnostics/plusAssignPrecedence.fir.diag.txt new file mode 100644 index 00000000000..620e688dc0e --- /dev/null +++ b/plugins/assign-plugin/testData/diagnostics/plusAssignPrecedence.fir.diag.txt @@ -0,0 +1,5 @@ +/plusAssignPrecedence.fir.kt:(2202,2204): error: Unresolved reference: plusAssign + +/plusAssignPrecedence.fir.kt:(2227,2229): error: Unresolved reference: plusAssign + +/plusAssignPrecedence.fir.kt:(2308,2310): error: Ambiguity between assign operator candidates: [fun plus(v: String): StringPropertyWithPlusAndPlusAssign, fun plusAssign(v: String): Unit]