AA: relax the assertion about referenced ClassId and qualified access

If an import alias is involved, they could be not identical.
Since an import alias ends with a simple identifer, we can simply drop
the first segment of qualified access and try the assertion again.
This commit is contained in:
Jinseong Jeon
2022-03-01 01:16:47 -08:00
committed by Ilya Kirillov
parent 7fbfb1bd95
commit a68fd25982
5 changed files with 60 additions and 4 deletions
@@ -0,0 +1,20 @@
// FILE: R.kt
package test.pkg
class R {
class string {
companion object {
val hello : Int = 42
}
}
}
// FILE: main.kt
package test.pkg
import test.pkg.R as coreR
fun box() {
val s = core<caret>R.string.hello
}
@@ -0,0 +1,2 @@
Resolved to:
0: (in test.pkg) class R