[FIR] KT-56212 Fix compilation exception caused by type parameter chain
- `FirTypeResolverImpl.resolveSymbol` cannot simply assert that a type parameter only has a single qualifier, because code may be fed to the compiler where a type parameter is the start of a type chain (see for example the added `typeParameterChainInReturnType` test). - The fix assumes that any multi-qualifier type parameter trivially resolves to `null`, because such a chained type cannot exist. ^KT-56212 fixed ^KTIJ-24083 fixed
This commit is contained in:
committed by
Space Team
parent
70ace38788
commit
d8671422b1
+2
@@ -0,0 +1,2 @@
|
||||
// ISSUE: KT-56212
|
||||
fun <F> <!UNRESOLVED_REFERENCE!>F.X<!>.f(): Boolean = false
|
||||
+2
@@ -0,0 +1,2 @@
|
||||
// ISSUE: KT-56212
|
||||
fun <F> F.<!UNRESOLVED_REFERENCE!>X<!>.f(): Boolean = false
|
||||
+3
@@ -0,0 +1,3 @@
|
||||
package
|
||||
|
||||
public fun </*0*/ F> [Error type: Unresolved type for F.X].f(): kotlin.Boolean
|
||||
+2
@@ -0,0 +1,2 @@
|
||||
// ISSUE: KT-56212
|
||||
fun <F> foo(): <!UNRESOLVED_REFERENCE!>F.X<!> = TODO()
|
||||
+2
@@ -0,0 +1,2 @@
|
||||
// ISSUE: KT-56212
|
||||
fun <F> foo(): F.<!UNRESOLVED_REFERENCE!>X<!> = TODO()
|
||||
+3
@@ -0,0 +1,3 @@
|
||||
package
|
||||
|
||||
public fun </*0*/ F> foo(): [Error type: Unresolved type for F.X]
|
||||
Reference in New Issue
Block a user