Skip to content

Commit 3eab35d

Browse files
committed
Kotlin: Small simplification
1 parent 4f7eb7b commit 3eab35d

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

java/kotlin-extractor/src/main/kotlin/KotlinFileExtractor.kt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1427,8 +1427,8 @@ open class KotlinFileExtractor(
14271427
// type arguments at index -2, -3, ...
14281428
extractTypeArguments(typeArguments, locId, id, enclosingCallable, enclosingStmt, -2, true)
14291429

1430-
val isFunctionInvoke = drType != null
1431-
&& drType is IrSimpleType
1430+
val isFunctionInvoke =
1431+
drType is IrSimpleType
14321432
&& drType.isFunctionOrKFunction()
14331433
&& callTarget.name.asString() == OperatorNameConventions.INVOKE.asString()
14341434
val isBigArityFunctionInvoke = isFunctionInvoke
@@ -1443,7 +1443,7 @@ open class KotlinFileExtractor(
14431443
extractNewExprForLocalFunction(ids, id, locId, enclosingCallable, enclosingStmt)
14441444
} else {
14451445
val methodId =
1446-
if (drType != null && extractClassTypeArguments && drType is IrSimpleType && !isUnspecialised(drType)) {
1446+
if (extractClassTypeArguments && drType is IrSimpleType && !isUnspecialised(drType)) {
14471447

14481448
val extractionMethod = if (isFunctionInvoke) {
14491449
// For `kotlin.FunctionX` and `kotlin.reflect.KFunctionX` interfaces, we're making sure that we

0 commit comments

Comments
 (0)