From 1a48b5750efbed02c8b9bf57bc3a850cd405c3a1 Mon Sep 17 00:00:00 2001 From: Alexander Udalov Date: Thu, 23 Apr 2015 16:45:48 +0300 Subject: [PATCH] Minor, remove unnecessary unwrapping of VariableAsFunctionResolvedCall Almost all of its methods delegate to functionCall already --- .../org/jetbrains/kotlin/codegen/ExpressionCodegen.java | 8 -------- 1 file changed, 8 deletions(-) diff --git a/compiler/backend/src/org/jetbrains/kotlin/codegen/ExpressionCodegen.java b/compiler/backend/src/org/jetbrains/kotlin/codegen/ExpressionCodegen.java index e36efec26c0..f33a8102320 100644 --- a/compiler/backend/src/org/jetbrains/kotlin/codegen/ExpressionCodegen.java +++ b/compiler/backend/src/org/jetbrains/kotlin/codegen/ExpressionCodegen.java @@ -2256,10 +2256,6 @@ public class ExpressionCodegen extends JetVisitor implem @NotNull public StackValue invokeFunction(@NotNull Call call, @NotNull ResolvedCall resolvedCall, @NotNull StackValue receiver) { - if (resolvedCall instanceof VariableAsFunctionResolvedCall) { - return invokeFunction(call, ((VariableAsFunctionResolvedCall) resolvedCall).getFunctionCall(), receiver); - } - FunctionDescriptor fd = accessibleFunctionDescriptor(resolvedCall); JetSuperExpression superCallExpression = getSuperCallExpression(call); boolean superCall = superCallExpression != null; @@ -2323,10 +2319,6 @@ public class ExpressionCodegen extends JetVisitor implem @NotNull ResolvedCall resolvedCall, @NotNull StackValue receiver ) { - if (resolvedCall instanceof VariableAsFunctionResolvedCall) { - resolvedCall = ((VariableAsFunctionResolvedCall) resolvedCall).getFunctionCall(); - } - CallGenerator callGenerator = getOrCreateCallGenerator(resolvedCall); CallableDescriptor descriptor = resolvedCall.getResultingDescriptor();