[FIR] Fix JVM mapped function callable id
This commit is contained in:
+5
@@ -1716,6 +1716,11 @@ public class Fir2IrTextTestGenerated extends AbstractFir2IrTextTest {
|
||||
public void testFirBuilder() throws Exception {
|
||||
runTest("compiler/testData/ir/irText/firProblems/FirBuilder.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("putIfAbsent.kt")
|
||||
public void testPutIfAbsent() throws Exception {
|
||||
runTest("compiler/testData/ir/irText/firProblems/putIfAbsent.kt");
|
||||
}
|
||||
}
|
||||
|
||||
@TestMetadata("compiler/testData/ir/irText/lambdas")
|
||||
|
||||
@@ -45,7 +45,7 @@ fun wrapScopeWithJvmMapped(
|
||||
(klass.symbol.constructType(
|
||||
klass.typeParameters.map { ConeTypeParameterTypeImpl(it.symbol.toLookupTag(), false) }.toTypedArray(),
|
||||
false
|
||||
) as ConeClassLikeType).wrapSubstitutionScopeIfNeed(useSiteSession, jvmMappedScope, klass, scopeSession)
|
||||
) as ConeClassLikeType).wrapSubstitutionScopeIfNeed(useSiteSession, jvmMappedScope, klass, scopeSession, klass.classId)
|
||||
}
|
||||
}
|
||||
} else {
|
||||
|
||||
@@ -88,7 +88,7 @@ fun ConeClassLikeType.wrapSubstitutionScopeIfNeed(
|
||||
useSiteMemberScope: FirTypeScope,
|
||||
declaration: FirClassLikeDeclaration<*>,
|
||||
builder: ScopeSession,
|
||||
derivedClassId: ClassId? = null
|
||||
derivedClassId: ClassId?
|
||||
): FirTypeScope {
|
||||
if (this.typeArguments.isEmpty()) return useSiteMemberScope
|
||||
return builder.getOrBuild(declaration.symbol, SubstitutionScopeKey(this)) {
|
||||
|
||||
+1
-1
@@ -45,7 +45,7 @@ class FirClassSubstitutionScope(
|
||||
constructor(
|
||||
session: FirSession, useSiteMemberScope: FirTypeScope, scopeSession: ScopeSession,
|
||||
substitution: Map<FirTypeParameterSymbol, ConeKotlinType>,
|
||||
skipPrivateMembers: Boolean, derivedClassId: ClassId? = null
|
||||
skipPrivateMembers: Boolean, derivedClassId: ClassId?
|
||||
) : this(session, useSiteMemberScope, scopeSession, substitutorByMap(substitution), skipPrivateMembers, derivedClassId)
|
||||
|
||||
override fun processFunctionsByName(name: Name, processor: (FirFunctionSymbol<*>) -> Unit) {
|
||||
|
||||
Reference in New Issue
Block a user