From 1804619076bb85aa3e9a64ba7a7b7d8efc3dc8f7 Mon Sep 17 00:00:00 2001 From: Nikolay Krasko Date: Thu, 26 Sep 2019 17:10:51 +0300 Subject: [PATCH] Fix AmbiguousCalls test in 192 --- .../importAllMembers/AmbiguousCalls.kt | 4 ++-- .../importAllMembers/AmbiguousCalls.kt.191 | 17 +++++++++++++++++ .../importAllMembers/AmbiguousCalls.kt.after | 4 ++-- .../AmbiguousCalls.kt.after.191 | 18 ++++++++++++++++++ 4 files changed, 39 insertions(+), 4 deletions(-) create mode 100644 idea/testData/intentions/importAllMembers/AmbiguousCalls.kt.191 create mode 100644 idea/testData/intentions/importAllMembers/AmbiguousCalls.kt.after.191 diff --git a/idea/testData/intentions/importAllMembers/AmbiguousCalls.kt b/idea/testData/intentions/importAllMembers/AmbiguousCalls.kt index a5c3d49a805..02a36ec7828 100644 --- a/idea/testData/intentions/importAllMembers/AmbiguousCalls.kt +++ b/idea/testData/intentions/importAllMembers/AmbiguousCalls.kt @@ -1,7 +1,7 @@ // INTENTION_TEXT: "Import members from 'javax.swing.SwingUtilities'" // WITH_RUNTIME -// ERROR: None of the following functions can be called with the arguments supplied:
public open fun convertPoint(source: Component!, aPoint: Point!, destination: Component!): Point! defined in javax.swing.SwingUtilities
public open fun convertPoint(source: Component!, x: Int, y: Int, destination: Component!): Point! defined in javax.swing.SwingUtilities -// ERROR: None of the following functions can be called with the arguments supplied:
public open fun convertPoint(source: Component!, aPoint: Point!, destination: Component!): Point! defined in javax.swing.SwingUtilities
public open fun convertPoint(source: Component!, x: Int, y: Int, destination: Component!): Point! defined in javax.swing.SwingUtilities +// ERROR: None of the following functions can be called with the arguments supplied:
@NotNull public open fun convertPoint(source: Component!, @NotNull aPoint: Point!, destination: Component!): Point! defined in javax.swing.SwingUtilities
public open fun convertPoint(source: Component!, x: Int, y: Int, destination: Component!): Point! defined in javax.swing.SwingUtilities +// ERROR: None of the following functions can be called with the arguments supplied:
@NotNull public open fun convertPoint(source: Component!, @NotNull aPoint: Point!, destination: Component!): Point! defined in javax.swing.SwingUtilities
public open fun convertPoint(source: Component!, x: Int, y: Int, destination: Component!): Point! defined in javax.swing.SwingUtilities // ERROR: Unresolved reference: unresolved import javax.swing.SwingUtilities diff --git a/idea/testData/intentions/importAllMembers/AmbiguousCalls.kt.191 b/idea/testData/intentions/importAllMembers/AmbiguousCalls.kt.191 new file mode 100644 index 00000000000..a5c3d49a805 --- /dev/null +++ b/idea/testData/intentions/importAllMembers/AmbiguousCalls.kt.191 @@ -0,0 +1,17 @@ +// INTENTION_TEXT: "Import members from 'javax.swing.SwingUtilities'" +// WITH_RUNTIME +// ERROR: None of the following functions can be called with the arguments supplied:
public open fun convertPoint(source: Component!, aPoint: Point!, destination: Component!): Point! defined in javax.swing.SwingUtilities
public open fun convertPoint(source: Component!, x: Int, y: Int, destination: Component!): Point! defined in javax.swing.SwingUtilities +// ERROR: None of the following functions can be called with the arguments supplied:
public open fun convertPoint(source: Component!, aPoint: Point!, destination: Component!): Point! defined in javax.swing.SwingUtilities
public open fun convertPoint(source: Component!, x: Int, y: Int, destination: Component!): Point! defined in javax.swing.SwingUtilities +// ERROR: Unresolved reference: unresolved + +import javax.swing.SwingUtilities + +fun foo() { + SwingUtilities.convertPoint() + + val bottom = SwingUtilities.BOTTOM + + SwingUtilities.convertPoint() + + SwingUtilities.unresolved +} diff --git a/idea/testData/intentions/importAllMembers/AmbiguousCalls.kt.after b/idea/testData/intentions/importAllMembers/AmbiguousCalls.kt.after index c147e62c172..e0c2101ad06 100644 --- a/idea/testData/intentions/importAllMembers/AmbiguousCalls.kt.after +++ b/idea/testData/intentions/importAllMembers/AmbiguousCalls.kt.after @@ -1,7 +1,7 @@ // INTENTION_TEXT: "Import members from 'javax.swing.SwingUtilities'" // WITH_RUNTIME -// ERROR: None of the following functions can be called with the arguments supplied:
public open fun convertPoint(source: Component!, aPoint: Point!, destination: Component!): Point! defined in javax.swing.SwingUtilities
public open fun convertPoint(source: Component!, x: Int, y: Int, destination: Component!): Point! defined in javax.swing.SwingUtilities -// ERROR: None of the following functions can be called with the arguments supplied:
public open fun convertPoint(source: Component!, aPoint: Point!, destination: Component!): Point! defined in javax.swing.SwingUtilities
public open fun convertPoint(source: Component!, x: Int, y: Int, destination: Component!): Point! defined in javax.swing.SwingUtilities +// ERROR: None of the following functions can be called with the arguments supplied:
@NotNull public open fun convertPoint(source: Component!, @NotNull aPoint: Point!, destination: Component!): Point! defined in javax.swing.SwingUtilities
public open fun convertPoint(source: Component!, x: Int, y: Int, destination: Component!): Point! defined in javax.swing.SwingUtilities +// ERROR: None of the following functions can be called with the arguments supplied:
@NotNull public open fun convertPoint(source: Component!, @NotNull aPoint: Point!, destination: Component!): Point! defined in javax.swing.SwingUtilities
public open fun convertPoint(source: Component!, x: Int, y: Int, destination: Component!): Point! defined in javax.swing.SwingUtilities // ERROR: Unresolved reference: unresolved import javax.swing.SwingUtilities diff --git a/idea/testData/intentions/importAllMembers/AmbiguousCalls.kt.after.191 b/idea/testData/intentions/importAllMembers/AmbiguousCalls.kt.after.191 new file mode 100644 index 00000000000..c147e62c172 --- /dev/null +++ b/idea/testData/intentions/importAllMembers/AmbiguousCalls.kt.after.191 @@ -0,0 +1,18 @@ +// INTENTION_TEXT: "Import members from 'javax.swing.SwingUtilities'" +// WITH_RUNTIME +// ERROR: None of the following functions can be called with the arguments supplied:
public open fun convertPoint(source: Component!, aPoint: Point!, destination: Component!): Point! defined in javax.swing.SwingUtilities
public open fun convertPoint(source: Component!, x: Int, y: Int, destination: Component!): Point! defined in javax.swing.SwingUtilities +// ERROR: None of the following functions can be called with the arguments supplied:
public open fun convertPoint(source: Component!, aPoint: Point!, destination: Component!): Point! defined in javax.swing.SwingUtilities
public open fun convertPoint(source: Component!, x: Int, y: Int, destination: Component!): Point! defined in javax.swing.SwingUtilities +// ERROR: Unresolved reference: unresolved + +import javax.swing.SwingUtilities +import javax.swing.SwingUtilities.* + +fun foo() { + convertPoint() + + val bottom = BOTTOM + + convertPoint() + + SwingUtilities.unresolved +}