vim-cpp-enhanced-highlight icon indicating copy to clipboard operation
vim-cpp-enhanced-highlight copied to clipboard

conditions can break highlighting

Open wreed4 opened this issue 9 years ago • 1 comments

The line "for ( int i=0; i<number; i++) ..." breaks highlighting for everything below it. To fix it, put a space after the "<". I imagine, this plugin is thinking the user is trying to create a template.

This is caused by the "experimental template highlighting". It may be a known bug. Sorry if it is.

(Also, yes there should be spaces there anyways, I agree. It's not my code :P)

wreed4 avatar Jul 17 '15 20:07 wreed4

Yes this is currently an unfortunate restriction. See also https://stackoverflow.com/questions/13627544/in-vim-is-there-any-way-to-define-syn-region-for-template-angle-brackets-withou for a discussion on this. Right now there is nothing in the pipeline that will fix this, but I of course accept patches.

octol avatar Jul 19 '15 22:07 octol