nerdcommenter icon indicating copy to clipboard operation
nerdcommenter copied to clipboard

s:HasCStyleComments expression fails in Vim 7.0

Open martijn opened this issue 13 years ago • 3 comments

This was encountered on Vim 7.0.237, the stock version for Red Hat and CentOS 5. When toggling a comment the expression in s:HasCStyleComments yields the following error:

E685: Internal error: get_tv_string_buf()
E116: Invalid arguments for function s:Left({'alt': 1}) == '/*' && s:Right({'alt': 1}) == '*/')
E15: Invalid expression: (s:Left() == '/*' && s:Right() == '*/') || (s:Left({'alt': 1}) == '/*' && s:Right({'alt': 1}) == '*/')

Since I lack vimscript-fu I don't know if this is easily fixed, but it sure would help for those of us stuck on older Vim versions. The error does not occur on newer Vim versions (the next oldest I have is 7.2.411 which works fine).

martijn avatar Dec 22 '11 21:12 martijn

Same problem here. Stuck on RedHats version of Vim and get the same error and also similar ones for different commenting tasks.

alexciarlillo avatar Aug 02 '12 15:08 alexciarlillo

Confirmed. Same issues as we are on RHEL 5.8. Seems that this is no longer 7.0 compliant.

gn0rt0n avatar Dec 08 '12 00:12 gn0rt0n

Is anybody still able to replicate this? I don't have problems in newer vim and it seems like this has probably been addressed. Am I missing something?

alerque avatar May 24 '16 12:05 alerque