Code completion plugin for c programming in Vim
Solution 1
I would always suggest using clang complete
like I did here. The other answers there might be useful for you as well.
Solution 2
Here is a long Article on the configuration, see if it helps you:
The autocompletion C/C + + in vim
Solution 3
I would strongly suggest the youcompleteme vim plugin.
https://github.com/ycm-core/YouCompleteMe#installation
Vimmer
Updated on September 09, 2020Comments
-
Vimmer over 3 years
I'm looking for a good code completion plugin for C programming in Vim. I already found some myself:
http://www.vim.org/scripts/script.php?script_id=1764 Even though this does have some very nice features, it only has a short gif file as documentation which makes it fairly useless to me. A shame really, I think it does almost what I want.
Ideally I want a plugin that knows the full C standard library, and has the features of the above plugin.
Any ideas?
-
R. Martinho Fernandes about 13 yearsI can't remember the details (it's been a while since I last used C, and I don't have a suitable environment at hand to confirm it), but I think I did this with a combination the out-of-the-box omni-completion and ctags. Opening vim and typing
:help ft-c-omni
should get you started. -
R. Martinho Fernandes about 13 yearsOh, and add some key remapping as well. I know of no one that likes the default
<C-X><C-O>
.
-