[AA] provide psiType#asKtType conversion
it's useful for IDE's features such as write UAST or refactorings ^KT-62302 fixed Merge-request: KT-MR-12414 Merged-by: Anna Kozlova <Anna.Kozlova@jetbrains.com>
This commit is contained in:
+11
@@ -0,0 +1,11 @@
|
||||
// FILE: B.kt
|
||||
class A<caret_onAirContext>K: A<String>() {
|
||||
}
|
||||
// FILE: A.java
|
||||
class A<T> {
|
||||
A<T> a = new A<>() {
|
||||
T f<caret>oo() {
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
+2
@@ -0,0 +1,2 @@
|
||||
PsiType: PsiType:T
|
||||
KtType: T?
|
||||
+8
@@ -0,0 +1,8 @@
|
||||
// FILE: B.kt
|
||||
interface B: A {
|
||||
fun f<caret_onAirContext>oo(): java.util.List<String?>?
|
||||
}
|
||||
// FILE: A.java
|
||||
public interface A {
|
||||
java.util.List<? extends String> fo<caret>o();
|
||||
}
|
||||
+2
@@ -0,0 +1,2 @@
|
||||
PsiType: PsiType:List<? extends String>
|
||||
KtType: kotlin.collections.List<kotlin.String?>?
|
||||
Vendored
+10
@@ -0,0 +1,10 @@
|
||||
// FILE: B.kt
|
||||
class B: A<String> {
|
||||
override fun <K : String?> f<caret_onAirContext>oo(): K? {
|
||||
TODO("Not yet implemented")
|
||||
}
|
||||
}
|
||||
// FILE: A.java
|
||||
public interface A<T> {
|
||||
<K extends T> K fo<caret>o();
|
||||
}
|
||||
Vendored
+2
@@ -0,0 +1,2 @@
|
||||
PsiType: PsiType:K
|
||||
KtType: K?
|
||||
Vendored
+8
@@ -0,0 +1,8 @@
|
||||
// FILE: B.kt
|
||||
interface B: A {
|
||||
fun fo<caret_onAirContext>o(): java.util.List<String?>?
|
||||
}
|
||||
// FILE: A.java
|
||||
public interface A {
|
||||
java.util.List<String> fo<caret>o();
|
||||
}
|
||||
Vendored
+2
@@ -0,0 +1,2 @@
|
||||
PsiType: PsiType:List<String>
|
||||
KtType: kotlin.collections.List<kotlin.String?>?
|
||||
Vendored
+8
@@ -0,0 +1,8 @@
|
||||
// FILE: B.kt
|
||||
interface B: A {
|
||||
fun f<caret_onAirContext>oo(): String?
|
||||
}
|
||||
// FILE: A.java
|
||||
public interface A {
|
||||
String fo<caret>o();
|
||||
}
|
||||
Vendored
+2
@@ -0,0 +1,2 @@
|
||||
PsiType: PsiType:String
|
||||
KtType: kotlin.String?
|
||||
+8
@@ -0,0 +1,8 @@
|
||||
// FILE: B.kt
|
||||
interface B: A {
|
||||
fun fo<caret_onAirContext>o(): Int
|
||||
}
|
||||
// FILE: A.java
|
||||
public interface A {
|
||||
int fo<caret>o();
|
||||
}
|
||||
+2
@@ -0,0 +1,2 @@
|
||||
PsiType: PsiType:int
|
||||
KtType: kotlin.Int
|
||||
Vendored
+8
@@ -0,0 +1,8 @@
|
||||
// FILE: B.kt
|
||||
interface B: A<String> {
|
||||
fun f<caret_onAirContext>oo(): String?
|
||||
}
|
||||
// FILE: A.java
|
||||
public interface A<T> {
|
||||
T f<caret>oo();
|
||||
}
|
||||
Vendored
+2
@@ -0,0 +1,2 @@
|
||||
PsiType: PsiType:T
|
||||
KtType: T?
|
||||
Vendored
+13
@@ -0,0 +1,13 @@
|
||||
// FILE: B.kt
|
||||
class AK: A<String>() {
|
||||
inner class BK: B<String>() {
|
||||
override fun <K : String?> f<caret_onAirContext>oo(): K {
|
||||
}
|
||||
}
|
||||
}
|
||||
// FILE: A.java
|
||||
class A<T> {
|
||||
abstract class B<S extends T> {
|
||||
abstract <K extends S> K f<caret>oo();
|
||||
}
|
||||
}
|
||||
Vendored
+2
@@ -0,0 +1,2 @@
|
||||
PsiType: PsiType:K
|
||||
KtType: K?
|
||||
Reference in New Issue
Block a user