From b5145ea68b0bb89d217cf53b35d5fa470f3bd51b Mon Sep 17 00:00:00 2001 From: Dmitry Petrov Date: Wed, 3 Feb 2016 17:54:14 +0300 Subject: [PATCH] Use implementation part class for SMAP generation when inlining function both from binaries and sources. --- .../org/jetbrains/kotlin/codegen/inline/InlineCodegen.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/compiler/backend/src/org/jetbrains/kotlin/codegen/inline/InlineCodegen.java b/compiler/backend/src/org/jetbrains/kotlin/codegen/inline/InlineCodegen.java index b4efec26291..6ac6879e542 100644 --- a/compiler/backend/src/org/jetbrains/kotlin/codegen/inline/InlineCodegen.java +++ b/compiler/backend/src/org/jetbrains/kotlin/codegen/inline/InlineCodegen.java @@ -213,7 +213,7 @@ public class InlineCodegen extends CallGenerator { } nodeAndSMAP = InlineCodegenUtil.getMethodNode( - file.contentsToByteArray(), asmMethod.getName(), asmMethod.getDescriptor(), containingClasses.getFacadeClassId() + file.contentsToByteArray(), asmMethod.getName(), asmMethod.getDescriptor(), containerId ); if (nodeAndSMAP == null) { @@ -241,7 +241,7 @@ public class InlineCodegen extends CallGenerator { SMAP smap; if (callDefault) { - Type implementationOwner = typeMapper.mapOwner(functionDescriptor); + Type implementationOwner = typeMapper.mapImplementationOwner(functionDescriptor); FakeMemberCodegen parentCodegen = new FakeMemberCodegen(codegen.getParentCodegen(), inliningFunction, (FieldOwnerContext) methodContext.getParentContext(), implementationOwner.getInternalName()); @@ -366,7 +366,7 @@ public class InlineCodegen extends CallGenerator { new FakeMemberCodegen(codegen.getParentCodegen(), expression, (FieldOwnerContext) context.getParentContext(), isLambda ? codegen.getParentCodegen().getClassName() - : typeMapper.mapOwner(descriptor).getInternalName()); + : typeMapper.mapImplementationOwner(descriptor).getInternalName()); FunctionGenerationStrategy strategy = expression instanceof KtCallableReferenceExpression ?