IR text tests: Don't dump signature mangled names for IR-based descriptors
^KT-57788
This commit is contained in:
committed by
Space Team
parent
07aad38c69
commit
cbf21acede
-3
@@ -1,8 +1,5 @@
|
|||||||
// TARGET_BACKEND: JVM
|
// TARGET_BACKEND: JVM
|
||||||
|
|
||||||
// MUTE_SIGNATURE_COMPARISON_K2: JVM_IR
|
|
||||||
// ^ KT-57788: Fix computing mangled names of types with @EnhancedNullability from IR-based declaration descriptors
|
|
||||||
|
|
||||||
// FILE: implicitNotNullOnDelegatedImplementation.kt
|
// FILE: implicitNotNullOnDelegatedImplementation.kt
|
||||||
interface IFoo {
|
interface IFoo {
|
||||||
fun foo(): String
|
fun foo(): String
|
||||||
|
|||||||
@@ -1,8 +1,5 @@
|
|||||||
// TARGET_BACKEND: JVM
|
// TARGET_BACKEND: JVM
|
||||||
|
|
||||||
// MUTE_SIGNATURE_COMPARISON_K2: JVM_IR
|
|
||||||
// ^ KT-57788: Fix computing mangled names of types with @EnhancedNullability from IR-based declaration descriptors
|
|
||||||
|
|
||||||
// FILE: kt43217.kt
|
// FILE: kt43217.kt
|
||||||
class A {
|
class A {
|
||||||
private val b =
|
private val b =
|
||||||
|
|||||||
@@ -1,13 +1,7 @@
|
|||||||
|
// TARGET_BACKEND: JVM
|
||||||
// WITH_STDLIB
|
// WITH_STDLIB
|
||||||
// FULL_JDK
|
// FULL_JDK
|
||||||
// JVM_TARGET: 1.8
|
// JVM_TARGET: 1.8
|
||||||
// IGNORE_BACKEND: JS_IR
|
|
||||||
|
|
||||||
// MUTE_SIGNATURE_COMPARISON_K2: JVM_IR JS_IR NATIVE
|
|
||||||
// ^ KT-57788: Fix computing mangled names of types with @EnhancedNullability from IR-based declaration descriptors
|
|
||||||
|
|
||||||
// KT-61141: ImplicitReceiverStack & PersistentImplicitReceiverStack miss fake overrides `forEach` & `spliterator`
|
|
||||||
// IGNORE_BACKEND: NATIVE
|
|
||||||
|
|
||||||
interface SymbolOwner<E : SymbolOwner<E>>
|
interface SymbolOwner<E : SymbolOwner<E>>
|
||||||
|
|
||||||
|
|||||||
+8
-8
@@ -15,6 +15,7 @@ import org.jetbrains.kotlin.descriptors.DescriptorVisibilities
|
|||||||
import org.jetbrains.kotlin.descriptors.PropertyDescriptor
|
import org.jetbrains.kotlin.descriptors.PropertyDescriptor
|
||||||
import org.jetbrains.kotlin.fir.backend.FirMangler
|
import org.jetbrains.kotlin.fir.backend.FirMangler
|
||||||
import org.jetbrains.kotlin.fir.backend.FirMetadataSource
|
import org.jetbrains.kotlin.fir.backend.FirMetadataSource
|
||||||
|
import org.jetbrains.kotlin.fir.declarations.FirDeclaration
|
||||||
import org.jetbrains.kotlin.ir.IrBuiltIns
|
import org.jetbrains.kotlin.ir.IrBuiltIns
|
||||||
import org.jetbrains.kotlin.ir.IrElement
|
import org.jetbrains.kotlin.ir.IrElement
|
||||||
import org.jetbrains.kotlin.ir.ObsoleteDescriptorBasedAPI
|
import org.jetbrains.kotlin.ir.ObsoleteDescriptorBasedAPI
|
||||||
@@ -226,14 +227,13 @@ class IrMangledNameAndSignatureDumpHandler(
|
|||||||
addSignatureTo(signatures, symbol.signature, ComputedBy.FE, isPublic = true)
|
addSignatureTo(signatures, symbol.signature, ComputedBy.FE, isPublic = true)
|
||||||
addSignatureTo(signatures, symbol.privateSignature, ComputedBy.FE, isPublic = false)
|
addSignatureTo(signatures, symbol.privateSignature, ComputedBy.FE, isPublic = false)
|
||||||
|
|
||||||
descriptorMangler.addSignatureMangledNameTo(signatureMangledNames, symbol.descriptor)
|
val firDeclaration: FirDeclaration? = ((declaration as? IrMetadataSourceOwner)?.metadata as? FirMetadataSource)?.fir
|
||||||
|
if (firDeclaration != null) {
|
||||||
((declaration as? IrMetadataSourceOwner)?.metadata as? FirMetadataSource)?.fir?.let {
|
// Dump only FIR-based signature mangled names if there is FIR available. In this mode no descriptors are used
|
||||||
firMangler?.addSignatureMangledNameTo(
|
// for computing signature mangled names.
|
||||||
signatureMangledNames,
|
firMangler?.addSignatureMangledNameTo(signatureMangledNames, firDeclaration)
|
||||||
it
|
} else
|
||||||
)
|
descriptorMangler.addSignatureMangledNameTo(signatureMangledNames, symbol.descriptor)
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
fun printActualMangledNamesAndSignatures() {
|
fun printActualMangledNamesAndSignatures() {
|
||||||
|
|||||||
-5
@@ -2124,11 +2124,6 @@ public class KlibIrTextTestCaseGenerated extends AbstractKlibIrTextTestCase {
|
|||||||
runTest("compiler/testData/ir/irText/firProblems/FirBuilder.kt");
|
runTest("compiler/testData/ir/irText/firProblems/FirBuilder.kt");
|
||||||
}
|
}
|
||||||
|
|
||||||
@TestMetadata("ImplicitReceiverStack.kt")
|
|
||||||
public void testImplicitReceiverStack() throws Exception {
|
|
||||||
runTest("compiler/testData/ir/irText/firProblems/ImplicitReceiverStack.kt");
|
|
||||||
}
|
|
||||||
|
|
||||||
@TestMetadata("inapplicableCollectionSet.kt")
|
@TestMetadata("inapplicableCollectionSet.kt")
|
||||||
public void testInapplicableCollectionSet() throws Exception {
|
public void testInapplicableCollectionSet() throws Exception {
|
||||||
runTest("compiler/testData/ir/irText/firProblems/inapplicableCollectionSet.kt");
|
runTest("compiler/testData/ir/irText/firProblems/inapplicableCollectionSet.kt");
|
||||||
|
|||||||
Generated
-6
@@ -2386,12 +2386,6 @@ public class FirLightTreeJsIrTextTestGenerated extends AbstractFirLightTreeJsIrT
|
|||||||
runTest("compiler/testData/ir/irText/firProblems/FirBuilder.kt");
|
runTest("compiler/testData/ir/irText/firProblems/FirBuilder.kt");
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
|
||||||
@TestMetadata("ImplicitReceiverStack.kt")
|
|
||||||
public void testImplicitReceiverStack() throws Exception {
|
|
||||||
runTest("compiler/testData/ir/irText/firProblems/ImplicitReceiverStack.kt");
|
|
||||||
}
|
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@TestMetadata("inapplicableCollectionSet.kt")
|
@TestMetadata("inapplicableCollectionSet.kt")
|
||||||
public void testInapplicableCollectionSet() throws Exception {
|
public void testInapplicableCollectionSet() throws Exception {
|
||||||
|
|||||||
-6
@@ -2386,12 +2386,6 @@ public class FirPsiJsIrTextTestGenerated extends AbstractFirPsiJsIrTextTest {
|
|||||||
runTest("compiler/testData/ir/irText/firProblems/FirBuilder.kt");
|
runTest("compiler/testData/ir/irText/firProblems/FirBuilder.kt");
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
|
||||||
@TestMetadata("ImplicitReceiverStack.kt")
|
|
||||||
public void testImplicitReceiverStack() throws Exception {
|
|
||||||
runTest("compiler/testData/ir/irText/firProblems/ImplicitReceiverStack.kt");
|
|
||||||
}
|
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@TestMetadata("inapplicableCollectionSet.kt")
|
@TestMetadata("inapplicableCollectionSet.kt")
|
||||||
public void testInapplicableCollectionSet() throws Exception {
|
public void testInapplicableCollectionSet() throws Exception {
|
||||||
|
|||||||
-6
@@ -2386,12 +2386,6 @@ public class ClassicJsIrTextTestGenerated extends AbstractClassicJsIrTextTest {
|
|||||||
runTest("compiler/testData/ir/irText/firProblems/FirBuilder.kt");
|
runTest("compiler/testData/ir/irText/firProblems/FirBuilder.kt");
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
|
||||||
@TestMetadata("ImplicitReceiverStack.kt")
|
|
||||||
public void testImplicitReceiverStack() throws Exception {
|
|
||||||
runTest("compiler/testData/ir/irText/firProblems/ImplicitReceiverStack.kt");
|
|
||||||
}
|
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@TestMetadata("inapplicableCollectionSet.kt")
|
@TestMetadata("inapplicableCollectionSet.kt")
|
||||||
public void testInapplicableCollectionSet() throws Exception {
|
public void testInapplicableCollectionSet() throws Exception {
|
||||||
|
|||||||
-6
@@ -2392,12 +2392,6 @@ public class ClassicNativeIrTextTestGenerated extends AbstractClassicNativeIrTex
|
|||||||
runTest("compiler/testData/ir/irText/firProblems/FirBuilder.kt");
|
runTest("compiler/testData/ir/irText/firProblems/FirBuilder.kt");
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
|
||||||
@TestMetadata("ImplicitReceiverStack.kt")
|
|
||||||
public void testImplicitReceiverStack() throws Exception {
|
|
||||||
runTest("compiler/testData/ir/irText/firProblems/ImplicitReceiverStack.kt");
|
|
||||||
}
|
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@TestMetadata("inapplicableCollectionSet.kt")
|
@TestMetadata("inapplicableCollectionSet.kt")
|
||||||
public void testInapplicableCollectionSet() throws Exception {
|
public void testInapplicableCollectionSet() throws Exception {
|
||||||
|
|||||||
-6
@@ -2392,12 +2392,6 @@ public class FirLightTreeNativeIrTextTestGenerated extends AbstractFirLightTreeN
|
|||||||
runTest("compiler/testData/ir/irText/firProblems/FirBuilder.kt");
|
runTest("compiler/testData/ir/irText/firProblems/FirBuilder.kt");
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
|
||||||
@TestMetadata("ImplicitReceiverStack.kt")
|
|
||||||
public void testImplicitReceiverStack() throws Exception {
|
|
||||||
runTest("compiler/testData/ir/irText/firProblems/ImplicitReceiverStack.kt");
|
|
||||||
}
|
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@TestMetadata("inapplicableCollectionSet.kt")
|
@TestMetadata("inapplicableCollectionSet.kt")
|
||||||
public void testInapplicableCollectionSet() throws Exception {
|
public void testInapplicableCollectionSet() throws Exception {
|
||||||
|
|||||||
-6
@@ -2392,12 +2392,6 @@ public class FirPsiNativeIrTextTestGenerated extends AbstractFirPsiNativeIrTextT
|
|||||||
runTest("compiler/testData/ir/irText/firProblems/FirBuilder.kt");
|
runTest("compiler/testData/ir/irText/firProblems/FirBuilder.kt");
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
|
||||||
@TestMetadata("ImplicitReceiverStack.kt")
|
|
||||||
public void testImplicitReceiverStack() throws Exception {
|
|
||||||
runTest("compiler/testData/ir/irText/firProblems/ImplicitReceiverStack.kt");
|
|
||||||
}
|
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@TestMetadata("inapplicableCollectionSet.kt")
|
@TestMetadata("inapplicableCollectionSet.kt")
|
||||||
public void testInapplicableCollectionSet() throws Exception {
|
public void testInapplicableCollectionSet() throws Exception {
|
||||||
|
|||||||
Reference in New Issue
Block a user