Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 322832

Summary: early field resolution leading to problems for ITDs when declare parents in use
Product: [Tools] AspectJ Reporter: Andrew Clement <aclement>
Component: CompilerAssignee: aspectj inbox <aspectj-inbox>
Status: RESOLVED FIXED QA Contact:
Severity: major    
Priority: P3    
Version: DEVELOPMENT   
Target Milestone: 1.6.10   
Hardware: PC   
OS: Windows 7   
Whiteboard:

Description Andrew Clement CLA 2010-08-16 15:33:00 EDT
I have a type that is being used where a generic is being expected.  That generic specifies an upper bound.  The type only obeys the upper bound once a declare parents has applied to it.

I have an intertype declaration (a field).  When the ITD is applied we do some work to see if it clashes with existing fields.  This causes existing fields to be resolved.  If this resolution triggers a bounds check for the declare parents affected type before the declare parents has applied, a problem will be raised.

Basically if the target of the declare is processed before the intertype then we are ok, but that is luck based.

We should do the declare parents first (and declare annotation) and then do intertype declarations (since they may trigger this extra resolution).
Comment 1 Andrew Clement CLA 2010-08-16 15:59:22 EDT
fix committed.