Bug 282948 - [AspectConvertingParser] type parameter in return type is causing spurious errors in editor
Summary: [AspectConvertingParser] type parameter in return type is causing spurious er...
Status: RESOLVED FIXED
Alias: None
Product: AJDT
Classification: Tools
Component: Core (show other bugs)
Version: unspecified   Edit
Hardware: Macintosh Mac OS X - Carbon (unsup.)
: P3 major (vote)
Target Milestone: 2.0.1   Edit
Assignee: AJDT-inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-07-08 22:49 EDT by Andrew Eisenberg CLA
Modified: 2009-09-24 18:34 EDT (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Andrew Eisenberg CLA 2009-07-08 22:49:58 EDT
I have this simple aspect and class that gives a spurious error in the editor:

public aspect RR {
    public R<?> R.c() {
        return null;
    }    
    after() : execution(R.new())  { }
    
}
class R<T> { }

Delete the '<?>' or the after advice and the spurious error disappears.
Comment 1 Andrew Eisenberg CLA 2009-07-08 23:04:59 EDT
It's the question mark.  Parser/scanner is thinking it is part of a  ? : operator;

Solution is to keep track of type parameter nesting.
Comment 2 Andrew Eisenberg CLA 2009-07-09 13:15:01 EDT
Fixed with regression tests.  Will be available in next dev build.

Also, addressed situations where there are nested type parameters, inner classes and inner aspects that use '?'.