diff --git a/compiler/ir/backend.jvm/src/org/jetbrains/kotlin/backend/jvm/lower/SingleAbstractMethodLowering.kt b/compiler/ir/backend.jvm/src/org/jetbrains/kotlin/backend/jvm/lower/SingleAbstractMethodLowering.kt index 9c0da7bf659..92ca84fed5b 100644 --- a/compiler/ir/backend.jvm/src/org/jetbrains/kotlin/backend/jvm/lower/SingleAbstractMethodLowering.kt +++ b/compiler/ir/backend.jvm/src/org/jetbrains/kotlin/backend/jvm/lower/SingleAbstractMethodLowering.kt @@ -92,7 +92,7 @@ class SingleAbstractMethodLowering(val context: CommonBackendContext) : FileLowe val instance = irCall(implementation.constructors.single()).apply { putValueArgument(0, irGet(invokableVariable)) } - irIfNull(superType, irGet(invokableVariable), irNull(), instance) + +irIfNull(superType, irGet(invokableVariable), irNull(), instance) } } else { irCall(implementation.constructors.single()).apply { putValueArgument(0, invokable) } diff --git a/compiler/testData/codegen/bytecodeText/sam/samWrapperForNullableInitialization.kt b/compiler/testData/codegen/bytecodeText/sam/samWrapperForNullableInitialization.kt index ec4e4f53af9..757821e3886 100644 --- a/compiler/testData/codegen/bytecodeText/sam/samWrapperForNullableInitialization.kt +++ b/compiler/testData/codegen/bytecodeText/sam/samWrapperForNullableInitialization.kt @@ -1,4 +1,3 @@ -// IGNORE_BACKEND: JVM_IR // FILE: JFoo.java import org.jetbrains.annotations.Nullable; @@ -17,8 +16,16 @@ fun test() { JFoo.foo2({}, runnable()) } -// @TestKt.class: // 2 NEW + +// JVM_TEMPLATES +// @TestKt.class: // 0 IFNONNULL // 1 IFNULL // 1 ACONST_NULL + +// JVM_IR_TEMPLATES +// @TestKt.class +// 1 IFNONNULL +// 0 IFNULL +// 2 ACONST_NULL