That's controlled by the setting
// Shows build errors just under the line on which they occur.
It defaults to being turned on, so it should Just Work without you having to do anything. That said, it does rely on the setup that you're using to build programs to tell it where the errors are, so if it's not working for you that might be why.
In that case if you can share your build information (in a new thread) we can probably help you work that out as well.