Bug 444398 - Abstract aspect hierarchy and annotation style leads to NPE
Summary: Abstract aspect hierarchy and annotation style leads to NPE
Status: RESOLVED FIXED
Alias: None
Product: AspectJ
Classification: Tools
Component: Compiler (show other bugs)
Version: 1.8.2   Edit
Hardware: PC Mac OS X
: P3 normal (vote)
Target Milestone: 1.8.3   Edit
Assignee: aspectj inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-09-17 13:43 EDT by Andrew Clement CLA
Modified: 2014-09-17 13:54 EDT (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Andrew Clement CLA 2014-09-17 13:43:00 EDT
import org.aspectj.lang.annotation.*;

@Aspect
public abstract class Bottom extends Middle {
}


import org.aspectj.lang.annotation.*;

@Aspect
public abstract class Middle extends Top {
}


public abstract class Top {
}

gives:
java.lang.NullPointerException
	at org.aspectj.ajdt.internal.compiler.lookup.EclipseSourceType.getPerClauseForTypeDeclaration(EclipseSourceType.java:1034)
Comment 1 Andrew Clement CLA 2014-09-17 13:53:48 EDT
There is an order to compilation required here too, to trigger the error:

"Bottom.java Middle.java Top.java"
Comment 2 Andrew Clement CLA 2014-09-17 13:54:18 EDT
Fix committed. I guess the guess of annotation style aspects extending regular classes just hasn't come up before.