Copy typeParameters from original declaration to the exportedDefaultStubFun before substitution of type parameters

This commit is contained in:
SokolovaMaria
2021-02-11 12:24:28 +03:00
parent 706d3e5aa8
commit 15aaf3a078
@@ -107,9 +107,9 @@ class ExportedDefaultParameterStub(val context: JsIrBackendContext) : Declaratio
context.additionalExportedDeclarations.add(exportedDefaultStubFun)
exportedDefaultStubFun.returnType = declaration.returnType.remapTypeParameters(declaration, exportedDefaultStubFun)
exportedDefaultStubFun.parent = declaration.parent
exportedDefaultStubFun.copyParameterDeclarationsFrom(declaration)
exportedDefaultStubFun.returnType = declaration.returnType.remapTypeParameters(declaration, exportedDefaultStubFun)
exportedDefaultStubFun.valueParameters.forEach { it.defaultValue = null }
declaration.origin = JsLoweredDeclarationOrigin.JS_SHADOWED_EXPORT