diff options
author | jhugunin <jhugunin> | 2002-12-18 01:08:50 +0000 |
---|---|---|
committer | jhugunin <jhugunin> | 2002-12-18 01:08:50 +0000 |
commit | 2a5c5a8d91b8362bbbdfd1c3a6d2459ca69feeaf (patch) | |
tree | ec0c4edc56635a3572f2bad518f3636aba1087f4 /weaver | |
parent | 9da1832d911c85b32c67391871db3b4943b4e599 (diff) | |
download | aspectj-2a5c5a8d91b8362bbbdfd1c3a6d2459ca69feeaf.tar.gz aspectj-2a5c5a8d91b8362bbbdfd1c3a6d2459ca69feeaf.zip |
handling privileged access to types correctly
fixed bugs in other privileged access handling
Diffstat (limited to 'weaver')
-rw-r--r-- | weaver/src/org/aspectj/weaver/bcel/BcelTypeMunger.java | 4 | ||||
-rw-r--r-- | weaver/src/org/aspectj/weaver/bcel/LazyClassGen.java | 4 |
2 files changed, 8 insertions, 0 deletions
diff --git a/weaver/src/org/aspectj/weaver/bcel/BcelTypeMunger.java b/weaver/src/org/aspectj/weaver/bcel/BcelTypeMunger.java index 89e085fba..63ab93d0c 100644 --- a/weaver/src/org/aspectj/weaver/bcel/BcelTypeMunger.java +++ b/weaver/src/org/aspectj/weaver/bcel/BcelTypeMunger.java @@ -71,6 +71,10 @@ public class BcelTypeMunger extends ConcreteTypeMunger { } else if (member.getKind() == Member.METHOD) { addMethodDispatch(gen, member, AjcMemberMaker.privilegedAccessMethodForMethod(aspectType, member)); + return true; + } else if (member.getKind() == Member.STATIC_INITIALIZATION) { + gen.forcePublic(); + return true; } else { throw new RuntimeException("unimplemented"); } diff --git a/weaver/src/org/aspectj/weaver/bcel/LazyClassGen.java b/weaver/src/org/aspectj/weaver/bcel/LazyClassGen.java index b3b4cced8..110ec064d 100644 --- a/weaver/src/org/aspectj/weaver/bcel/LazyClassGen.java +++ b/weaver/src/org/aspectj/weaver/bcel/LazyClassGen.java @@ -487,4 +487,8 @@ public final class LazyClassGen { throw new BCException("Class " + this.getName() + " does not have a method " + name + " with signature " + signature); } + + public void forcePublic() { + myGen.setAccessFlags(Utility.makePublic(myGen.getAccessFlags())); + } } |