Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is there any C/C++ editor in Linux that shows errors while typing

The Visual C++ editor has a great feature which is that it underlines errors with a red line while typing the code. So for example, if you are using a variable that is not declared, it will underline it with a red curly line. In this way, the programmer can resolve a lot of errors while typing and doesn't have to wait for compiling for noticing them.

Now my question is, is there any editor for Linux that has this great feature?

like image 846
MetallicPriest Avatar asked Jul 23 '11 10:07

MetallicPriest


3 Answers

Kdevelop4 has some features you requested. For example, it will underline undeclared variables with yellow and underline files that cannot be found with red. But in my opinion currently it yields in this functionality to MSVS2010.

like image 198
eugene_che Avatar answered Sep 21 '22 21:09

eugene_che


Vim has a plugin, called c.vim. It enables syntax checking for C and C++.
You can read more about it in the support file and this tutorial.

I think this is the closest thing I know to what you want, using an editor.
If instead, by editor you include IDEs then, Netbeans and Eclise offer that functionality.

like image 20
c00kiemon5ter Avatar answered Sep 21 '22 21:09

c00kiemon5ter


If you plan on using a "simple" editor, I can only recommend Clang Complete for vim.

The plugin uses Clang under the hood to provide real-time feedback on errors, plus auto-completion.

You need to download/install Clang separately.

like image 40
Matthieu M. Avatar answered Sep 22 '22 21:09

Matthieu M.