Commits

Jonathan Gilbert committed 3d4100a

now allows using Scala objects for injection

  • Participants
  • Parent commits 91378c7

Comments (0)

Files changed (1)

File mangler/src/main/scala/org/trillica/mangley/adapter/ContextCallSwitcher.scala

     new MethodAdapter(super.visitMethod(access, name, desc, signature, exceptions)) {
 
       override def visitMethodInsn(opcode: Int, owner: String, name: String, desc: String) = {
-        if (!owner.equals(contextType.getInternalName()))
+        if (!owner.equals(contextType.getInternalName()) && !owner.equals(contextType.getInternalName() + "$"))
           super.visitMethodInsn(opcode: Int, owner: String, name: String, desc: String)
         else
           super.visitLdcInsn(ManglingContext.current().methodId)