[FIR] Fix dispatch receivers on inner classes' constructors
1. Inner class constructor should have its outer class as a dispatch receiver, since it is necessary for the call. Before it was null 2. Substituted inner class constructor should have its original dispatch receiver type with the proper substitution. Before it was set to the class itself (since the class was usually passed as a new dispatch receiver) Also, modify FIR renderer, so it properly renders the dispatch receiver of the constructors
This commit is contained in:
+1
-1
@@ -6,7 +6,7 @@ public open class RawSuperType : R|kotlin/Any| {
|
||||
|
||||
@R|java/lang/Override|() public open fun dummy(): R|kotlin/Unit|
|
||||
|
||||
public constructor(): R|test/RawSuperType.Derived|
|
||||
public test/RawSuperType.constructor(): R|test/RawSuperType.Derived|
|
||||
|
||||
}
|
||||
public abstract interface Super<T : R|ft<kotlin/Any, kotlin/Any?>|> : R|kotlin/Any| {
|
||||
|
||||
+1
-1
@@ -10,7 +10,7 @@ public open class RawSuperTypeWithBound : R|kotlin/Any| {
|
||||
|
||||
@R|java/lang/Override|() public open fun dummy(): R|kotlin/Unit|
|
||||
|
||||
public constructor(): R|test/RawSuperTypeWithBound.Derived|
|
||||
public test/RawSuperTypeWithBound.constructor(): R|test/RawSuperTypeWithBound.Derived|
|
||||
|
||||
}
|
||||
public abstract interface Super<T : R|ft<test/RawSuperTypeWithBound.Bound, test/RawSuperTypeWithBound.Bound?>|> : R|kotlin/Any| {
|
||||
|
||||
Vendored
+1
-1
@@ -8,7 +8,7 @@ public open class RawSuperTypeWithRecursiveBound : R|kotlin/Any| {
|
||||
|
||||
@R|java/lang/Override|() public open fun dummy(): R|kotlin/Unit|
|
||||
|
||||
public constructor(): R|test/RawSuperTypeWithRecursiveBound.Derived|
|
||||
public test/RawSuperTypeWithRecursiveBound.constructor(): R|test/RawSuperTypeWithRecursiveBound.Derived|
|
||||
|
||||
}
|
||||
public abstract interface Super<T : R|ft<test/RawSuperTypeWithRecursiveBound.Super<ft<T, T?>>, test/RawSuperTypeWithRecursiveBound.Super<ft<T, T?>>?>|> : R|kotlin/Any| {
|
||||
|
||||
+1
-1
@@ -8,7 +8,7 @@ public open class RawSuperTypeWithRecursiveBoundMultipleParameters : R|kotlin/An
|
||||
|
||||
@R|java/lang/Override|() public open fun dummy(): R|kotlin/Unit|
|
||||
|
||||
public constructor(): R|test/RawSuperTypeWithRecursiveBoundMultipleParameters.Derived|
|
||||
public test/RawSuperTypeWithRecursiveBoundMultipleParameters.constructor(): R|test/RawSuperTypeWithRecursiveBoundMultipleParameters.Derived|
|
||||
|
||||
}
|
||||
public abstract interface Super<R : R|ft<kotlin/Any, kotlin/Any?>|, T : R|ft<test/RawSuperTypeWithRecursiveBoundMultipleParameters.Super<ft<R, R?>, ft<T, T?>>, test/RawSuperTypeWithRecursiveBoundMultipleParameters.Super<ft<R, R?>, ft<T, T?>>?>|> : R|kotlin/Any| {
|
||||
|
||||
+2
-2
@@ -5,7 +5,7 @@ public abstract interface ReturnInnerSubclassOfSupersInner : R|kotlin/Any| {
|
||||
public/*package*/ open inner class Inner<B : R|ft<kotlin/Any, kotlin/Any?>|> : R|test/ReturnInnerSubclassOfSupersInner.Super.Inner<ft<B, B?>>| {
|
||||
public/*package*/ open operator fun get(): R|ft<test/ReturnInnerSubclassOfSupersInner.Sub<ft<B, B?>>, test/ReturnInnerSubclassOfSupersInner.Sub<ft<B, B?>>?>|
|
||||
|
||||
public/*package*/ constructor(): R|test/ReturnInnerSubclassOfSupersInner.Sub.Inner<B>|
|
||||
public/*package*/ test/ReturnInnerSubclassOfSupersInner.Sub<B>.constructor(): R|test/ReturnInnerSubclassOfSupersInner.Sub.Inner<B>|
|
||||
|
||||
}
|
||||
}
|
||||
@@ -15,7 +15,7 @@ public abstract interface ReturnInnerSubclassOfSupersInner : R|kotlin/Any| {
|
||||
public/*package*/ open inner class Inner<A : R|ft<kotlin/Any, kotlin/Any?>|> : R|kotlin/Any| {
|
||||
public/*package*/ open operator fun get(): R|ft<test/ReturnInnerSubclassOfSupersInner.Super<ft<A, A?>>, test/ReturnInnerSubclassOfSupersInner.Super<ft<A, A?>>?>|
|
||||
|
||||
public/*package*/ constructor(): R|test/ReturnInnerSubclassOfSupersInner.Super.Inner<A>|
|
||||
public/*package*/ test/ReturnInnerSubclassOfSupersInner.Super<A>.constructor(): R|test/ReturnInnerSubclassOfSupersInner.Super.Inner<A>|
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user