1

After updating vim, it behaves very irrationally when I try to edit a c or cpp file. Here is a picture:

screenshot

I have tried to debug a bit, and both

vim -u NORC -N --cmd 'call pathogen#infect()' file.c

and

vim --noplugin file.c

eliminates the problem, which is strange, as the first one uses plugins but no vimrc, and the second one vimrc but no plugins.

I am indeed using pathogen and if relevant (or actually, regardless of that), here are the plugins I'm using: nerdcommenter, vim-airline, vim-glsl, vim-session, nerdtree, vim-airlineish, vim-gradle, YouCompleteMe, TagHighlight, vim-autoclose, vim-misc

This is my .vimrc: https://bpaste.net/show/9910268a2e20

I tried to debug using :finish, and found out that the error is caused by line 69:

filetype plugin indent on

Same thing if I replace it by:

filetype on

But that's maybe obvious as the problem seems to only happen (as far as I have tried) on c and cpp files.

closed as off-topic by Martin Tournoij Mar 2 '16 at 15:43

This question appears to be off-topic. The users who voted to close gave this specific reason:

  • "This question was caused by a problem that can no longer be reproduced or a simple typographical error. While similar questions may be on-topic here, this one was resolved in a manner unlikely to help future readers." – Martin Tournoij
If this question can be reworded to fit the rules in the help center, please edit the question.

  • 1
    Try commenting out your plugin settings plugin by plugin in your vimrc. Do you have any custom ftplugin files? Your vimrc has the call to pathogen commented out. – muru Sep 19 '15 at 1:48
  • I uncommented pathogen, and commented out all the plugin settings, but I still have the problem. I have ftdetect/z80.vim; I also tried vim a.c while that directory is empty. Also, clearing my bundle directory, the problem persists.. How does that differ from vim --noplugin file.c? – Ploppz Sep 19 '15 at 12:07
  • Had a similar problem. Disabling clang-complete worked for me. – carloabelli Sep 19 '15 at 18:32
  • 1
    @muru Yes that would appear correct. I seems related to the recent ncurses update. Here's some info info: github.com/Rip-Rip/clang_complete/issues/453 and bbs.archlinux.org/viewtopic.php?id=202590. – carloabelli Sep 20 '15 at 18:59
  • 1
    Solution: there were some clang-related files in .vim/plugin. I don't know how they got there, but deleting plugin solved the problem. – Ploppz Sep 30 '15 at 20:17

Browse other questions tagged or ask your own question.