In Eclipse, when I make any code changes it automatically shows all compilation errors in the workspace in a console. It seems like in IntelliJ I have to make/build the project in order to see any compilation errors. Is there a window/tab to show all compilation errors?
Show all errors in one place:The Problems tool window appears if the Make project automatically option is enabled in the Compiler settings. It shows a list of problems that were detected on project compilation. Use the Eclipse compiler: This is actually bundled in IntelliJ.
In "Settings" --> Build, Execution, Deployment --> "Compiler" check the checkbox "Build project automatically". This will immediately show any compile errors in the project tree.
Background compilation (auto-build)You can configure IntelliJ IDEA to build your project automatically, every time you make changes to it. The results of the background compilation are displayed in the Problems tool window.
Navigate between errors or warnings To jump to the next or previous found issue in your code, press F2 or Shift+F2 respectively. Alternatively, from the main menu, select Navigate | Next / Previous Highlighted Error. IntelliJ IDEA places the caret immediately before the code issue.
Nowadays you have the same option as in eclipse to have automatic builds when you save.
Edit
Any changes in the editor will now trigger a compilation either when Ctrl+s is pressed or after a short interval.
This first image will show a main method and a class with a simple print
method. No compilation errors.
In the next image I have removed the parameter message
in the print
method. That's the only thing I did, I did not even save I just waited a couple of seconds. And then suddenly the compilation error is shown below because the caller of the method has now supplied too many arguments.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With