[FIR] KT-58523: Check the companion presence when resolving type-aliases
The change in `QualifiedNameResolution.kt` is backed by `starImportOnTypeAlias.fir.kt` and `javaStaticMembersViaTypeAlias.fir.kt`. Note that referencing inner classes via type-aliases is prohibited, but referencing enum entries is not. ^KT-58523 Fixed
This commit is contained in:
committed by
Space Team
parent
99ff36c77a
commit
7b45f75213
-18
@@ -1,18 +0,0 @@
|
||||
// ISSUE: KT-58523
|
||||
|
||||
// FILE: pkg.kt
|
||||
|
||||
package pkg
|
||||
|
||||
class Klass
|
||||
typealias ItemKey = Klass
|
||||
|
||||
// FILE: main.kt
|
||||
|
||||
import pkg.ItemKey
|
||||
|
||||
val ItemKey = 42
|
||||
|
||||
fun main() {
|
||||
<!NO_COMPANION_OBJECT!>ItemKey<!> // K1: ok, K2: NO_COMPANION_OBJECT
|
||||
}
|
||||
@@ -1,3 +1,4 @@
|
||||
// FIR_IDENTICAL
|
||||
// ISSUE: KT-58523
|
||||
|
||||
// FILE: pkg.kt
|
||||
|
||||
Reference in New Issue
Block a user