From: aclement Date: Tue, 30 Sep 2008 22:55:35 +0000 (+0000) Subject: 186884: fix X-Git-Tag: V1_6_2~10 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=7a398a2d4cfe14c36662ac6b984303f8ba920362;p=aspectj.git 186884: fix --- diff --git a/weaver/src/org/aspectj/weaver/bcel/BcelShadow.java b/weaver/src/org/aspectj/weaver/bcel/BcelShadow.java index c753f7472..20110f517 100644 --- a/weaver/src/org/aspectj/weaver/bcel/BcelShadow.java +++ b/weaver/src/org/aspectj/weaver/bcel/BcelShadow.java @@ -229,7 +229,10 @@ public class BcelShadow extends Shadow { InstructionHandle dupHandle = endHandle; endHandle = endHandle.getNext(); nextHandle = endHandle.getNext(); + boolean skipEndRepositioning = false; if (endHandle.getInstruction().opcode == Constants.SWAP) { + } else if (endHandle.getInstruction().opcode == Constants.IMPDEP1) { + skipEndRepositioning = true; // pr186884 } else { // XXX see next XXX comment throw new RuntimeException("Unhandled kind of new " + endHandle); @@ -237,7 +240,9 @@ public class BcelShadow extends Shadow { // Now make any jumps to the 'new', the 'dup' or the 'end' now target the nextHandle retargetFrom(newHandle, nextHandle); retargetFrom(dupHandle, nextHandle); - retargetFrom(endHandle, nextHandle); + if (!skipEndRepositioning) { + retargetFrom(endHandle, nextHandle); + } } else { endHandle = newHandle; nextHandle = endHandle.getNext(); @@ -261,7 +266,6 @@ public class BcelShadow extends Shadow { for (int i = sources.length - 1; i >= 0; i--) { if (sources[i] instanceof ExceptionRange) { ExceptionRange it = (ExceptionRange) sources[i]; - System.err.println("..."); it.updateTarget(old, fresh, it.getBody()); } else { sources[i].updateTarget(old, fresh);