Bug 464994

Summary: NullPointerException during first weaving
Product: [Tools] AspectJ Reporter: Dada Hsu <for.shin1223>
Component: CompilerAssignee: aspectj inbox <aspectj-inbox>
Status: NEW --- QA Contact:
Severity: normal    
Priority: P3 CC: aclement
Version: 1.8.5   
Target Milestone: ---   
Hardware: PC   
OS: Windows 7   
Whiteboard:

Description Dada Hsu CLA 2015-04-20 06:17:23 EDT
Hi, all
I always get a exception when Eclipse auto-build after cleaning all projects.
But if I touch the file and save it, the triggered auto-build is always  successful.

--
java.lang.NullPointerException
at org.aspectj.ajdt.internal.core.builder.EclipseSourceContext.getSourceFile(EclipseSourceContext.java:49)
at org.aspectj.ajdt.internal.core.builder.EclipseSourceContext.makeSourceLocation(EclipseSourceContext.java:57)
at org.aspectj.weaver.bcel.BcelShadow.getSourceLocation(BcelShadow.java:3390)
at org.aspectj.weaver.model.AsmRelationshipProvider.findOrCreateCodeNode(AsmRelationshipProvider.java:950)

--
It really bothers me.
Comment 1 Andrew Clement CLA 2015-04-23 15:30:28 EDT
I'd need to recreate this to dig into it - is it by any a public project? Can you trim down your project to a smaller one that exhibits the same problem?  I can stick in a guard but it will likely have unexpected consequences.  Compilation results shouldn't forget the source file they came from.