diff options
author | Andy Clement <andrew.clement@gmail.com> | 2012-06-15 17:42:25 -0700 |
---|---|---|
committer | Andy Clement <andrew.clement@gmail.com> | 2012-06-15 17:42:25 -0700 |
commit | a7483038e86dd39894d9b347f227eb6c3a33e09e (patch) | |
tree | 4a0b8bdfa50bb7d26814f0aff6d6f1ebca32b1de /weaver | |
parent | ba9d43ccaf2660ddc9916ea48f79a77ba60d435e (diff) | |
download | aspectj-a7483038e86dd39894d9b347f227eb6c3a33e09e.tar.gz aspectj-a7483038e86dd39894d9b347f227eb6c3a33e09e.zip |
382189 and 382435
Diffstat (limited to 'weaver')
-rw-r--r-- | weaver/src/org/aspectj/weaver/bcel/BcelTypeMunger.java | 30 |
1 files changed, 7 insertions, 23 deletions
diff --git a/weaver/src/org/aspectj/weaver/bcel/BcelTypeMunger.java b/weaver/src/org/aspectj/weaver/bcel/BcelTypeMunger.java index ac9bacf84..2ae4ac91a 100644 --- a/weaver/src/org/aspectj/weaver/bcel/BcelTypeMunger.java +++ b/weaver/src/org/aspectj/weaver/bcel/BcelTypeMunger.java @@ -1240,7 +1240,9 @@ public class BcelTypeMunger extends ConcreteTypeMunger { boolean quitRightNow = false; String localMethodName = unMangledInterMethod.getName(); - String localParameterSig = unMangledInterMethod.getParameterSignature(); + String erasedSig = unMangledInterMethod.getSignatureErased(); // will be something like (LSuperB;)LFoo; + String localParameterSig = erasedSig.substring(0,erasedSig.lastIndexOf(')')+1);//unMangledInterMethod.getParameterSignature(); + // getParameterSignatureErased() does not include parens, which we do need. String localReturnTypeESig = unMangledInterMethod.getReturnType().getErasureSignature(); // Step1 @@ -1295,28 +1297,10 @@ public class BcelTypeMunger extends ConcreteTypeMunger { InstructionFactory fact; int pos = 0; - LazyMethodGen bridgeMethod = makeMethodGen(clazz, theBridgeMethod); // The - // bridge - // method - // in - // this - // type - // will - // have - // the - // same - // signature - // as - // the - // one - // in - // the - // supertype - bridgeMethod.setAccessFlags(bridgeMethod.getAccessFlags() | 0x00000040 /* - * BRIDGE = 0x00000040 - */); - // UnresolvedType[] newParams = - // munger.getSignature().getParameterTypes(); + // The bridge method in this type will have the same signature as the one in the supertype + LazyMethodGen bridgeMethod = makeMethodGen(clazz, theBridgeMethod); + bridgeMethod.setAccessFlags(bridgeMethod.getAccessFlags() | 0x00000040 /* BRIDGE = 0x00000040 */); + // UnresolvedType[] newParams = munger.getSignature().getParameterTypes(); Type returnType = BcelWorld.makeBcelType(theBridgeMethod.getReturnType()); body = bridgeMethod.getBody(); fact = clazz.getFactory(); |