Remove unnecessary check from prepareCodeToInline

This commit is contained in:
Mikhail Glukhikh
2017-07-26 17:42:36 +03:00
committed by Mikhail Glukhikh
parent 1ed1751b63
commit c2617e89c9
@@ -64,8 +64,7 @@ class CodeToInlineBuilder(
processReferences(codeToInline, bindingContext)
// NB: we must check in codeToInline, otherwise we get AE from addPostInsertionAction
if (mainExpression != null && mainExpression in codeToInline) {
if (mainExpression != null) {
val functionLiteralExpression = mainExpression.unpackFunctionLiteral(true)
if (functionLiteralExpression != null) {
val functionLiteralParameterTypes = getParametersForFunctionLiteral(functionLiteralExpression, bindingContext)