Java editor shows compiler errors, compilation succeeds


I have a scenario where a custom annotation processor has been created and used to provide some modifications of the source code Abstract Syntax Tree (AST). While the project builds successfully in IntelliJ IDEA 12.1.6 Community edition, the editor shows some errors also the created methods/fields are not shown in the structure.
I've attached a test project which you can import and see the problem. I'm also attaching a sample diagram of the scenario and a screenshot of the errors in the IDE.

I did some more research and found that IntelliJ uses internal parser of the Java Code (, which appears to not have notion of the custom annotation processor.

Do you have an idea how we can avoid this in-editor error? Is it possible the java editor to reflect the source code after the annotation processing.

Best Regards,

P.S. Writing some custom plugin for IntelliJ IDEA to handle this is also OK if possible and supported by the platform. So please advise if that is achievable.

1 comment
Comment actions Permalink

IDEA analyzes sources, not a compiled files - so missing fileld is of couse an error.
Yes, a plugin is needed to support this, the one for Lombok may serve as a reference.


Please sign in to leave a comment.