Due to the latest improvements, an error which was previously not thrown unexpectedly according to a source code comment in test aspect ParameterizedTypesInAnnotationPatterns.aj is now thrown for this kind of pointcut: staticinitialization(@(Foo || List<String>) String) Now the compiler correctly says: no static initialization join points for parameterized types, use raw type instead Relates to #221. Signed-off-by: Alexander Kriegisch <Alexander@Kriegisch.name>pull/222/head
@@ -3,10 +3,9 @@ import java.util.List; | |||
public aspect ParameterizedTypesInAnnotationPatterns { | |||
// CE - not an annotation type | |||
pointcut simple() : staticinitialization(@List<String> String); | |||
// no CE, good enough for now? may improve error reporting for this later | |||
// CE - no static initialization join points for parameterized types, use raw type instead | |||
pointcut combined() : staticinitialization(@(Foo || List<String>) String); | |||
} | |||
@interface Foo {} | |||
@interface Foo {} |
@@ -5017,6 +5017,7 @@ | |||
<ajc-test dir="java5/generics/pointcuts" title="annotation patterns with parameterized types"> | |||
<compile files="ParameterizedTypesInAnnotationPatterns.aj" options="-1.5"> | |||
<message kind="error" line="5" text="is not an annotation type"/> | |||
<message kind="error" line="8" text="no static initialization join points for parameterized types, use raw type instead"/> | |||
</compile> | |||
</ajc-test> | |||
@@ -5017,6 +5017,7 @@ | |||
<ajc-test dir="java5/generics/pointcuts" title="annotation patterns with parameterized types"> | |||
<compile files="ParameterizedTypesInAnnotationPatterns.aj" options="-1.9"> | |||
<message kind="error" line="5" text="is not an annotation type"/> | |||
<message kind="error" line="8" text="no static initialization join points for parameterized types, use raw type instead"/> | |||
</compile> | |||
</ajc-test> | |||