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

Bug 328121

Summary: missing relationship map entry for declare @method
Product: [Tools] AspectJ Reporter: Andrew Clement <aclement>
Component: CompilerAssignee: aspectj inbox <aspectj-inbox>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: P3    
Version: DEVELOPMENT   
Target Milestone: 1.6.12   
Hardware: PC   
OS: Windows 7   
Whiteboard:

Description Andrew Clement CLA 2010-10-19 08:29:44 EDT
There is no entry in the relmap for this program:

package TestRequirements;

import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;


@Retention(RetentionPolicy.RUNTIME)
@interface AnnotatedMethod {}

@Retention(RetentionPolicy.RUNTIME)
@interface NewAnnotatedMethod {
	boolean newValue();
}

aspect X {
	declare @method: !@AnnotatedMethod * TestRequirements.*(..) : @NewAnnotatedMethod(newValue = true);
}

class TestRequirements {
	@AnnotatedMethod
	public void dontMatchMe() {}
	
	public void matchMe() {}
}
Comment 1 Andrew Clement CLA 2011-04-28 16:02:49 EDT
The problem here is that the typename is the same as the package name.  Rather unusual!

fixed.