From a71f09022c4723821d5058f9066dfb2a735df730 Mon Sep 17 00:00:00 2001 From: Dmitry Savvinov Date: Mon, 6 Aug 2018 15:04:28 +0300 Subject: [PATCH] Fix testdata after switching idea version to 182 The source of changes is commit the following commit in intelllij-community repo: b2b723fa449b16bb1da8102a5efdc219977fefe0 speedup java class resolve a bit Eseentially, it makes Java resolve (which Kotlin reuses) accept first matching candidate from explicit named import, instead of continuing search. Hence, behavior in cases where several conflicting imports are present, has changed: before, reference to such names were unresolved, now it's candidate from first import (see also test UsageMixed.java in the intellij-community repo). Therefore, previously we saw such types as undeclared and reported MISSING_DEPENDENCY_CLASS on them (assuming they are not present in classpath); now we see such types as properly resolved, so error is gone. Because behavior has changed only in case there already was "red" code, it is not a BC and we can just accept changes. --- .../javac/diagnostics/tests/imports/ClassImportsConflicting.kt | 2 +- .../diagnostics/tests/imports/NestedAndTopLevelClassClash.kt | 2 +- .../javac/diagnostics/tests/imports/NestedClassClash.kt | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/compiler/testData/javac/diagnostics/tests/imports/ClassImportsConflicting.kt b/compiler/testData/javac/diagnostics/tests/imports/ClassImportsConflicting.kt index 895418c20a9..6be1ea2d0be 100644 --- a/compiler/testData/javac/diagnostics/tests/imports/ClassImportsConflicting.kt +++ b/compiler/testData/javac/diagnostics/tests/imports/ClassImportsConflicting.kt @@ -27,4 +27,4 @@ import a.a class A : a() -fun test() = A().getO() +fun test() = A().getO() diff --git a/compiler/testData/javac/diagnostics/tests/imports/NestedAndTopLevelClassClash.kt b/compiler/testData/javac/diagnostics/tests/imports/NestedAndTopLevelClassClash.kt index 2575f29b93f..0a0b01dc673 100644 --- a/compiler/testData/javac/diagnostics/tests/imports/NestedAndTopLevelClassClash.kt +++ b/compiler/testData/javac/diagnostics/tests/imports/NestedAndTopLevelClassClash.kt @@ -33,5 +33,5 @@ public class A2 { // FILE: a.kt package b -fun test() = A1().getB() +fun test() = A1().getB() fun test2() = A2().getB() \ No newline at end of file diff --git a/compiler/testData/javac/diagnostics/tests/imports/NestedClassClash.kt b/compiler/testData/javac/diagnostics/tests/imports/NestedClassClash.kt index b3f09a6fb46..5c87f114623 100644 --- a/compiler/testData/javac/diagnostics/tests/imports/NestedClassClash.kt +++ b/compiler/testData/javac/diagnostics/tests/imports/NestedClassClash.kt @@ -35,5 +35,5 @@ public class A2 { // FILE: a.kt package b -fun test() = A1().getB() +fun test() = A1().getB() fun test2() = A2().getB()