FIR: set dispatch receiver type to constructor in deserialization
This commit is contained in:
+1
-1
@@ -5,7 +5,7 @@
|
||||
}
|
||||
|
||||
@R|kotlin/Deprecated|(message = String(Inner)) public final inner class Inner : R|kotlin/Any| {
|
||||
public constructor(): R|test/Class.Inner|
|
||||
public test/Class.constructor(): R|test/Class.Inner|
|
||||
|
||||
}
|
||||
|
||||
|
||||
Vendored
+1
-1
@@ -13,7 +13,7 @@ public final annotation class Anno : R|kotlin/Annotation| {
|
||||
}
|
||||
|
||||
@R|test/Anno|(t = R|java/lang/annotation/ElementType.PARAMETER|()) public final inner class Inner : R|kotlin/Any| {
|
||||
public constructor(): R|test/Class.Inner|
|
||||
public test/Class.constructor(): R|test/Class.Inner|
|
||||
|
||||
}
|
||||
|
||||
|
||||
Vendored
+1
-1
@@ -5,7 +5,7 @@ public final annotation class Anno : R|kotlin/Annotation| {
|
||||
|
||||
public final class Class : R|kotlin/Any| {
|
||||
@R|test/Anno|() public final inner class Inner : R|kotlin/Any| {
|
||||
public constructor(): R|test/Class.Inner|
|
||||
public test/Class.constructor(): R|test/Class.Inner|
|
||||
|
||||
}
|
||||
|
||||
|
||||
+1
-1
@@ -11,7 +11,7 @@ public final class Outer : R|kotlin/Any| {
|
||||
public final val y: R|kotlin/String|
|
||||
public get(): R|kotlin/String|
|
||||
|
||||
public constructor(@R|test/A|(s = String(inner)) y: R|kotlin/String|): R|test/Outer.Inner|
|
||||
public test/Outer.constructor(@R|test/A|(s = String(inner)) y: R|kotlin/String|): R|test/Outer.Inner|
|
||||
|
||||
}
|
||||
|
||||
|
||||
Vendored
+1
-1
@@ -26,7 +26,7 @@ public final class Generic<T> : R|kotlin/Any| {
|
||||
|
||||
public final class InnerGeneric<A, B> : R|kotlin/Any| {
|
||||
public final inner class Inner<in C, D : R|A|, A, B> : R|kotlin/Any| {
|
||||
public constructor<in C, D : R|A|>(): R|test/InnerGeneric.Inner<C, D, A, B>|
|
||||
public test/InnerGeneric<A, B>.constructor<in C, D : R|A|>(): R|test/InnerGeneric.Inner<C, D, A, B>|
|
||||
|
||||
}
|
||||
|
||||
|
||||
+1
-1
@@ -1,6 +1,6 @@
|
||||
public final class Outer : R|kotlin/Any| {
|
||||
public final inner class Inner : R|kotlin/Any| {
|
||||
public constructor(): R|test/Outer.Inner|
|
||||
public test/Outer.constructor(): R|test/Outer.Inner|
|
||||
|
||||
}
|
||||
|
||||
|
||||
Vendored
+2
-2
@@ -1,11 +1,11 @@
|
||||
public final class Outer : R|kotlin/Any| {
|
||||
public open inner class Inner1 : R|kotlin/Any| {
|
||||
public constructor(): R|test/Outer.Inner1|
|
||||
public test/Outer.constructor(): R|test/Outer.Inner1|
|
||||
|
||||
}
|
||||
|
||||
public final inner class Inner2 : R|test/Outer.Inner1| {
|
||||
public constructor(): R|test/Outer.Inner2|
|
||||
public test/Outer.constructor(): R|test/Outer.Inner2|
|
||||
|
||||
}
|
||||
|
||||
|
||||
+1
-1
@@ -1,6 +1,6 @@
|
||||
public final class Outer : R|kotlin/Any| {
|
||||
public final inner class Inner<T> : R|kotlin/Any| {
|
||||
public constructor<T>(): R|test/Outer.Inner<T>|
|
||||
public test/Outer.constructor<T>(): R|test/Outer.Inner<T>|
|
||||
|
||||
}
|
||||
|
||||
|
||||
+3
-3
@@ -3,16 +3,16 @@ public final class Outer<E, F> : R|kotlin/Any| {
|
||||
public final inner class Inner3<I, G, H, E, F> : R|kotlin/Any| {
|
||||
public final fun foo(x: R|test/Outer.Inner<G, kotlin/Int, kotlin/String, F>|, y: R|test/Outer.Inner<E, kotlin/Double, E, F>|, z: R|test/Outer.Inner.Inner3<kotlin/Double, G, kotlin/Int, kotlin/String, F>|, w: R|test/Outer.Inner.Inner3<*, G, H, E, F>|): R|kotlin/Unit|
|
||||
|
||||
public constructor<I>(): R|test/Outer.Inner.Inner3<I, G, H, E, F>|
|
||||
public test/Outer.Inner<G, H, E, F>.constructor<I>(): R|test/Outer.Inner.Inner3<I, G, H, E, F>|
|
||||
|
||||
}
|
||||
|
||||
public constructor<G, H>(): R|test/Outer.Inner<G, H, E, F>|
|
||||
public test/Outer<E, F>.constructor<G, H>(): R|test/Outer.Inner<G, H, E, F>|
|
||||
|
||||
}
|
||||
|
||||
public final inner class Inner2<E, F> : R|kotlin/Any| {
|
||||
public constructor(): R|test/Outer.Inner2<E, F>|
|
||||
public test/Outer<E, F>.constructor(): R|test/Outer.Inner2<E, F>|
|
||||
|
||||
}
|
||||
|
||||
|
||||
Vendored
+2
-2
@@ -9,12 +9,12 @@ public final class TestFirst : R|kotlin/Any| {
|
||||
}
|
||||
|
||||
public final inner class InnerClass : R|kotlin/Any| {
|
||||
public constructor(): R|test/TestFirst.InnerClass|
|
||||
public test/TestFirst.constructor(): R|test/TestFirst.InnerClass|
|
||||
|
||||
}
|
||||
|
||||
public final inner class NotInnerClass : R|kotlin/Any| {
|
||||
public constructor(): R|test/TestFirst.NotInnerClass|
|
||||
public test/TestFirst.constructor(): R|test/TestFirst.NotInnerClass|
|
||||
|
||||
}
|
||||
|
||||
|
||||
+1
-1
@@ -1,6 +1,6 @@
|
||||
public final enum class Enum : R|kotlin/Enum<test/Enum>| {
|
||||
public final inner class Inner : R|kotlin/Any| {
|
||||
public constructor(): R|test/Enum.Inner|
|
||||
public test/Enum.constructor(): R|test/Enum.Inner|
|
||||
|
||||
}
|
||||
|
||||
|
||||
+1
-1
@@ -1,6 +1,6 @@
|
||||
public open class InnerClass : R|kotlin/Any| {
|
||||
public open inner class Inner : R|kotlin/Any| {
|
||||
public constructor(): R|test/InnerClass.Inner|
|
||||
public test/InnerClass.constructor(): R|test/InnerClass.Inner|
|
||||
|
||||
}
|
||||
|
||||
|
||||
+2
-2
@@ -5,7 +5,7 @@ public final class O : R|kotlin/Any| {
|
||||
}
|
||||
|
||||
public final inner class A2 : R|kotlin/Any| {
|
||||
public constructor(): R|test/O.A2|
|
||||
public test/O.constructor(): R|test/O.A2|
|
||||
|
||||
}
|
||||
|
||||
@@ -15,7 +15,7 @@ public final class O : R|kotlin/Any| {
|
||||
}
|
||||
|
||||
public final inner class B2 : R|kotlin/Any| {
|
||||
public constructor(): R|test/O.B2|
|
||||
public test/O.constructor(): R|test/O.B2|
|
||||
|
||||
}
|
||||
|
||||
|
||||
+3
-3
@@ -6,15 +6,15 @@ public final class A<TA> : R|kotlin/Any| {
|
||||
|
||||
public final fun <P1, P2, P3, P4> foo(p1: R|P1|, p2: R|P2|, p3: R|P3|, p4: R|P4|): R|kotlin/Nothing|
|
||||
|
||||
public constructor<TD>(): R|test/A.B.C.D<TD, TC, TB, TA>|
|
||||
public test/A.B.C<TC, TB, TA>.constructor<TD>(): R|test/A.B.C.D<TD, TC, TB, TA>|
|
||||
|
||||
}
|
||||
|
||||
public constructor<TC>(): R|test/A.B.C<TC, TB, TA>|
|
||||
public test/A.B<TB, TA>.constructor<TC>(): R|test/A.B.C<TC, TB, TA>|
|
||||
|
||||
}
|
||||
|
||||
public constructor<TB>(): R|test/A.B<TB, TA>|
|
||||
public test/A<TA>.constructor<TB>(): R|test/A.B<TB, TA>|
|
||||
|
||||
}
|
||||
|
||||
|
||||
Vendored
+1
-1
@@ -1,6 +1,6 @@
|
||||
public final class InnerClassReferencesOuterTP<P> : R|kotlin/Any| {
|
||||
public final inner class Inner<Q : R|P|, P> : R|kotlin/Any| {
|
||||
public constructor<Q : R|P|>(): R|test/InnerClassReferencesOuterTP.Inner<Q, P>|
|
||||
public test/InnerClassReferencesOuterTP<P>.constructor<Q : R|P|>(): R|test/InnerClassReferencesOuterTP.Inner<Q, P>|
|
||||
|
||||
}
|
||||
|
||||
|
||||
+1
-1
@@ -10,7 +10,7 @@ public final class MembersReferenceOuterTP<P> : R|kotlin/Any| {
|
||||
public final val <Q : R|P|> R|Q|.w: R|Q|
|
||||
public get(): R|Q|
|
||||
|
||||
public constructor(): R|test/MembersReferenceOuterTP.Inner<P>|
|
||||
public test/MembersReferenceOuterTP<P>.constructor(): R|test/MembersReferenceOuterTP.Inner<P>|
|
||||
|
||||
}
|
||||
|
||||
|
||||
+8
-2
@@ -49,7 +49,7 @@ class FirDeserializationContext(
|
||||
val constDeserializer: FirConstDeserializer,
|
||||
val containerSource: DeserializedContainerSource?,
|
||||
val outerClassSymbol: FirRegularClassSymbol?,
|
||||
outerTypeParameters: List<FirTypeParameterSymbol>
|
||||
val outerTypeParameters: List<FirTypeParameterSymbol>
|
||||
) {
|
||||
val session: FirSession = moduleData.session
|
||||
|
||||
@@ -527,6 +527,7 @@ class FirMemberDeserializer(private val c: FirDeserializationContext) {
|
||||
origin = FirDeclarationOrigin.Library
|
||||
returnTypeRef = delegatedSelfType
|
||||
val visibility = ProtoEnumFlags.visibility(Flags.VISIBILITY.get(flags))
|
||||
val isInner = classBuilder.status.isInner
|
||||
status = FirResolvedDeclarationStatusImpl(
|
||||
visibility,
|
||||
Modality.FINAL,
|
||||
@@ -535,9 +536,14 @@ class FirMemberDeserializer(private val c: FirDeserializationContext) {
|
||||
isExpect = Flags.IS_EXPECT_FUNCTION.get(flags)
|
||||
isActual = false
|
||||
isOverride = false
|
||||
isInner = classBuilder.status.isInner
|
||||
this.isInner = isInner
|
||||
}
|
||||
this.symbol = symbol
|
||||
dispatchReceiverType =
|
||||
if (!isInner) null
|
||||
else with(c) {
|
||||
ClassId(packageFqName, relativeClassName.parent(), false).defaultType(outerTypeParameters)
|
||||
}
|
||||
resolvePhase = FirResolvePhase.ANALYZED_DEPENDENCIES
|
||||
this.typeParameters +=
|
||||
typeParameters.filterIsInstance<FirTypeParameter>()
|
||||
|
||||
Reference in New Issue
Block a user