Bug 450374 - hasmethod() does not work in @DeclareParents
Summary: hasmethod() does not work in @DeclareParents
Status: NEW
Alias: None
Product: AspectJ
Classification: Tools
Component: Compiler (show other bugs)
Version: 1.8.3   Edit
Hardware: PC Windows NT
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: aspectj inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-11-06 12:01 EST by Alexander Kriegisch CLA
Modified: 2014-11-06 12:01 EST (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Alexander Kriegisch CLA 2014-11-06 12:01:00 EST
I know it is a non-standard feature, but I just noticed that while hasmember() works fine in native syntax, it does not seem to work in @AspectJ syntax.

This works:

	declare parents : hasmethod(@MyAttribute * *(..)) implements Moody;

This does not:

	@DeclareParents(value = "hasmethod(@de.scrum_master.app.MyAttribute * *(..))", defaultImpl = Moody.class)
	private Moody annotatedMethods;

In the latter case the compiler with -XhasMember on says:

        no match for this type name: hasmethod [Xlint:invalidAbsoluteTypeName]