@@ -701,22 +701,6 @@ trait BCodeBodyBuilder extends BCodeSkelBuilder {
701
701
else genSynchronized(app, expectedType)
702
702
703
703
case Apply (fun @ DesugaredSelect (Super (_, _), _), args) =>
704
- def initModule (): Unit = {
705
- // we initialize the MODULE$ field immediately after the super ctor
706
- if (! isModuleInitialized &&
707
- jMethodName == INSTANCE_CONSTRUCTOR_NAME &&
708
- fun.symbol.javaSimpleName == INSTANCE_CONSTRUCTOR_NAME &&
709
- claszSymbol.isStaticModuleClass) {
710
- isModuleInitialized = true
711
- mnode.visitVarInsn(asm.Opcodes .ALOAD , 0 )
712
- mnode.visitFieldInsn(
713
- asm.Opcodes .PUTSTATIC ,
714
- thisName,
715
- str.MODULE_INSTANCE_FIELD ,
716
- " L" + thisName + " ;"
717
- )
718
- }
719
- }
720
704
// 'super' call: Note: since constructors are supposed to
721
705
// return an instance of what they construct, we have to take
722
706
// special care. On JVM they are 'void', and Scala forbids (syntactically)
@@ -726,7 +710,6 @@ trait BCodeBodyBuilder extends BCodeSkelBuilder {
726
710
mnode.visitVarInsn(asm.Opcodes .ALOAD , 0 )
727
711
genLoadArguments(args, paramTKs(app))
728
712
generatedType = genCallMethod(fun.symbol, InvokeStyle .Super , app.span)
729
- initModule()
730
713
731
714
// 'new' constructor call: Note: since constructors are
732
715
// thought to return an instance of what they construct,
0 commit comments