Community
Participate
Working Groups
import java.util.*; public class Bug { public HashSet<Integer> _public; private HashSet<Integer> _private; private HashSet typeless; public static void main(String[] args) { } } privileged aspect Spy { after() : execution(void main(String[])) { HashSet _typeless = new Bug().typeless; // works HashSet<Integer> _public = new Bug()._public; // works HashSet<Integer> _private = new Bug()._private; // fails to compile } }
Can you confirm the crash you see? Is it this one? C:\Bug.aj [error] Internal compiler error org.aspectj.weaver.BCException: Bad type signature < at org.aspectj.weaver.TypeX.forSignature(TypeX.java:207) at org.aspectj.weaver.Member.signatureToTypes(Member.java:153) at org.aspectj.weaver.Member.<init>(Member.java:54) at org.aspectj.weaver.ResolvedMember.<init>(ResolvedMember.java:80) at org.aspectj.weaver.AjcMemberMaker.privilegedAccessMethodForFieldSet(AjcMemberMaker.java:318) at org.aspectj.ajdt.internal.compiler.lookup.PrivilegedFieldBinding.<init>(PrivilegedFieldBinding.java:41) Related to parsing of generic signatures.
yes, it is.
*** Bug 97092 has been marked as a duplicate of this bug. ***
Although the stack trace is different to 97763, the fix for that bug fixes this one too. Thanks for the simple test program!! Waiting for dev build to be available before closing...
Fixed in latest dev build from http://eclipse.org/aspectj/downloads.php