FIR LC: add tests about type approximation in PsiType provider
This commit is contained in:
committed by
Roman Golyshev
parent
c441980c74
commit
9ed2c9d371
Vendored
+3
@@ -0,0 +1,3 @@
|
||||
fun f<caret>oo() = object : Runnable {
|
||||
override fun run() {}
|
||||
}
|
||||
Vendored
+2
@@ -0,0 +1,2 @@
|
||||
KtType: java.lang.Runnable
|
||||
PsiType: PsiType:Runnable
|
||||
Vendored
+6
@@ -0,0 +1,6 @@
|
||||
fun f<caret>oo(): Runnable {
|
||||
class Local : Runnable {
|
||||
override fun run() {}
|
||||
}
|
||||
return Local()
|
||||
}
|
||||
Vendored
+2
@@ -0,0 +1,2 @@
|
||||
KtType: java.lang.Runnable
|
||||
PsiType: PsiType:Runnable
|
||||
+8
@@ -0,0 +1,8 @@
|
||||
private fun f<caret>oo() = run {
|
||||
class Local {
|
||||
fun bar(): Local {
|
||||
return this
|
||||
}
|
||||
}
|
||||
val p = Local().bar()
|
||||
}
|
||||
+2
@@ -0,0 +1,2 @@
|
||||
KtType: kotlin.Unit
|
||||
PsiType: PsiType:Unit
|
||||
Vendored
+5
@@ -0,0 +1,5 @@
|
||||
fun foo() {
|
||||
class Local {
|
||||
}
|
||||
fun b<caret>ar() = Local()
|
||||
}
|
||||
Vendored
+2
@@ -0,0 +1,2 @@
|
||||
KtType: Local
|
||||
PsiType: PsiType:Object
|
||||
Vendored
+8
@@ -0,0 +1,8 @@
|
||||
fun foo() = run {
|
||||
class Local {
|
||||
fun bar(): Local {
|
||||
return this
|
||||
}
|
||||
}
|
||||
val p<caret> = Local().bar()
|
||||
}
|
||||
Vendored
+2
@@ -0,0 +1,2 @@
|
||||
KtType: Local
|
||||
PsiType: PsiType:Object
|
||||
+7
@@ -0,0 +1,7 @@
|
||||
fun foo() {
|
||||
class Local {
|
||||
}
|
||||
val a<caret> = fun (): Local {
|
||||
return Local()
|
||||
}
|
||||
}
|
||||
+2
@@ -0,0 +1,2 @@
|
||||
KtType: () -> Local
|
||||
PsiType: PsiType:Function0<? extends Object>
|
||||
+8
@@ -0,0 +1,8 @@
|
||||
fun foo() {
|
||||
class Local {
|
||||
fun b<caret>ar(): Local {
|
||||
return this
|
||||
}
|
||||
}
|
||||
val a = Local().bar()
|
||||
}
|
||||
+2
@@ -0,0 +1,2 @@
|
||||
KtType: Local
|
||||
PsiType: PsiType:Object
|
||||
Reference in New Issue
Block a user