Allow secondary constructors without body
#KT-6967 Fixed
This commit is contained in:
@@ -1176,7 +1176,9 @@ public class ImplementationBodyCodegen extends ClassBodyCodegen {
|
||||
JetSecondaryConstructor constructor =
|
||||
(JetSecondaryConstructor) DescriptorToSourceUtils.descriptorToDeclaration(constructorDescriptor);
|
||||
assert constructor != null;
|
||||
codegen.gen(constructor.getBodyExpression(), Type.VOID_TYPE);
|
||||
if (constructor.hasBody()) {
|
||||
codegen.gen(constructor.getBodyExpression(), Type.VOID_TYPE);
|
||||
}
|
||||
|
||||
iv.visitInsn(RETURN);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user