[FIR] Don't approximate captured types
This fixes some type argument mismatch errors caused by a captured type being approximated and then captured again. Some places need to be adapted to work with captured types that previously only worked with approximated types. #KT-62959 Fixed
This commit is contained in:
committed by
Space Team
parent
b6d7f35ebf
commit
251827c9aa
@@ -2,9 +2,6 @@
|
||||
// ISSUE: KT-52838
|
||||
|
||||
// IGNORE_LIGHT_ANALYSIS
|
||||
// IGNORE_BACKEND_K2: WASM
|
||||
// REASON: That still doesn't work properly with PCLA, but accidentally don't fails for other tests but WASM
|
||||
// (see KT-52838 for tracking and same-named diagnostic test)
|
||||
|
||||
fun box(): String {
|
||||
build {
|
||||
|
||||
@@ -1,10 +1,6 @@
|
||||
// ISSUE: KT-52838
|
||||
// JVM_ABI_K1_K2_DIFF: KT-64738
|
||||
|
||||
// IGNORE_BACKEND_K2: WASM
|
||||
// REASON: That still doesn't work properly with PCLA, but accidentally don't fails for other tests but WASM
|
||||
// (see KT-52838 for tracking and same-named diagnostic test)
|
||||
|
||||
fun box(): String {
|
||||
build {
|
||||
this as DerivedBuildee<*>
|
||||
|
||||
@@ -1,3 +1,9 @@
|
||||
MODULE main
|
||||
Missing in K2
|
||||
TestKt$example$2.class
|
||||
CLASS TestKt$example$1.class
|
||||
Property: class.signature
|
||||
K1
|
||||
Lkotlin/jvm/internal/Lambda;Lkotlin/jvm/functions/Function1<*Lkotlin/Unit;>;
|
||||
K2
|
||||
NULL
|
||||
|
||||
@@ -0,0 +1,33 @@
|
||||
MODULE main
|
||||
Missing in K1
|
||||
_1Kt$sam$Consumer$0.class
|
||||
CLASS User$use$1.class
|
||||
Property: class.signature
|
||||
K1
|
||||
<T:Ljava/lang/Object;>Ljava/lang/Object;LConsumer;
|
||||
K2
|
||||
NULL
|
||||
Property: class.superClassInternalName
|
||||
K1
|
||||
java/lang/Object
|
||||
K2
|
||||
kotlin/jvm/internal/Lambda
|
||||
Property: class.superInterfaces
|
||||
K1
|
||||
[Consumer]
|
||||
K2
|
||||
[kotlin/jvm/functions/Function1]
|
||||
K1
|
||||
consume(Ljava/lang/Object;)V [public, final]
|
||||
K2
|
||||
---
|
||||
K1
|
||||
---
|
||||
K2
|
||||
invoke(Ljava/lang/Object;)V [public, final]
|
||||
FIELD INSTANCE:LUser$use$1;
|
||||
Property: field.signature
|
||||
K1
|
||||
LUser$use$1<TT;>;
|
||||
K2
|
||||
NULL
|
||||
@@ -3,6 +3,7 @@
|
||||
// SAM_CONVERSIONS: CLASS
|
||||
// ^ test checks reflection for synthetic classes
|
||||
// MODULE: lib
|
||||
// JVM_ABI_K1_K2_DIFF: KT-64954
|
||||
// FILE: Promise.java
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
|
||||
|
||||
+3
@@ -0,0 +1,3 @@
|
||||
MODULE main
|
||||
Missing in K1
|
||||
BoxKt$test$2.class
|
||||
+1
@@ -1,6 +1,7 @@
|
||||
// TARGET_BACKEND: JVM
|
||||
// FULL_JDK
|
||||
// JVM_TARGET: 1.8
|
||||
// JVM_ABI_K1_K2_DIFF: KT-64954
|
||||
// FILE: J.java
|
||||
|
||||
import java.util.function.*;
|
||||
|
||||
Reference in New Issue
Block a user