Annotations are not supported at this language level


I run Idea 6. The project has jdk 1.6.0 defined. I have a class with annotations:

public class WSTest

In editor the annotation is underlined with red with message:
"Annotations are not supported at this language level"

I already set "-source 1.5" compiler parameter, so class is compiled successfully.
I also checked that in Settings->Errors->IDE Profiles->Default->Java Language level issues->Annotation box is unchecked.

But in IDEA editor I still see this error. Please help.

1 comment
Comment actions Permalink

Settings -> Project Structure -> Project 'xyz' -> Project language level


Please sign in to leave a comment.