Community
Participate
Working Groups
Just upgraded to latest AJDT (Version: 1.3.1, Build id: 20060322082516 AspectJ version: 1.5.1.20060320075953) and the compiler crashed while rebulding the project (which used to work fine using using the March 16th version). Retrying with 'clean' build produced the same crash. java.lang.NullPointerException at org.aspectj.weaver.AnnotationX.ensureAtTargetInitialized(AnnotationX.java:158) at org.aspectj.weaver.AnnotationX.specifiesTarget(AnnotationX.java:98) at org.aspectj.weaver.bcel.BcelWeaver.verifyTargetIsOK(BcelWeaver.java:1450) at org.aspectj.weaver.bcel.BcelWeaver.applyDeclareAtType(BcelWeaver.java:1417) at org.aspectj.weaver.bcel.BcelWeaver.weaveParentTypeMungers(BcelWeaver.java:1366) at org.aspectj.weaver.bcel.BcelWeaver.weaveParentsFor(BcelWeaver.java:1223) at org.aspectj.weaver.bcel.BcelWeaver.weaveParentsFor(BcelWeaver.java:1211) at org.aspectj.weaver.bcel.BcelWeaver.weave(BcelWeaver.java:1058) at org.aspectj.ajdt.internal.compiler.AjCompilerAdapter.weave(AjCompilerAdapter.java:311) at org.aspectj.ajdt.internal.compiler.AjCompilerAdapter.afterCompiling(AjCompilerAdapter.java:183) at org.aspectj.ajdt.internal.compiler.CompilerAdapter.ajc$afterReturning$org_aspectj_ajdt_internal_compiler_CompilerAdapter$2$f9cc9ca0(CompilerAdapter.aj:70) at org.aspectj.org.eclipse.jdt.internal.compiler.Compiler.compile(Compiler.java:367) at org.aspectj.ajdt.internal.core.builder.AjBuildManager.performCompilation(AjBuildManager.java:845) at org.aspectj.ajdt.internal.core.builder.AjBuildManager.doBuild(AjBuildManager.java:241) at org.aspectj.ajdt.internal.core.builder.AjBuildManager.batchBuild(AjBuildManager.java:161) at org.aspectj.ajde.internal.CompilerAdapter.compile(CompilerAdapter.java:122) at org.aspectj.ajde.internal.AspectJBuildManager$CompilerThread.run(AspectJBuildManager.java:191) NullPointerException thrown: null
I wonder if this is related to #128655. There is one major difference, though. #128655 crahsed only during incremental compilation, whereas this one crahses on full build.
this is no doubt because of the ASM support I added recently which has only just made it into an AJDT build. Can you try putting this in the 'non standard options' field for the offending project? -Xset:activateLightweightDelegates=false does it help it get past the NPE?
after looking a little further at it - I'm even more convinced its the ASM code since now annotations can be of two types depending on whether we loaded an ASM delegate for a type or a BCEL delegate for a type. I missed a path in the annotation processing code that should have done different things based on the kind of delegate loaded.
I just tried the suggested "-Xset:activateLightweightDelegates=false" option and could get a successful compilation.
Excellent - the option is doing exactly what I wanted - it deactivates the loading of classes via the ASM bytecode toolkit which is the problem here. I'll fix the bug soon as I can, now that I've finished doing my 40,000 sessions at AOSD.
fix for this checked into AJ now.
fix available now in 1.5.1 - will be in AJDT shortly.