cohama / lexima.vim

Auto close parentheses and repeat by dot dot dot...
996 stars 46 forks source link

Mysterious errors when adding newline #15

Closed smackesey closed 8 years ago

smackesey commented 9 years ago

In the following buffer (cursor indicated by "|" at the end of the last line), pressing return gives me a series of errors.


---
id: vkegrjzo
key: vimscript_vim-sneak.lib.vkegrjzo
type:
- library
title: vim-sneak
language: vimscript.pgl.bxsevhau
github: justinmk/vim-sneak

---|

These are the errors:

=<SNR>79_map_impl('
E115: Missing quote: '
E116: Invalid arguments for function <SNR>79_map_impl('
E15: Invalid expression: <SNR>79_map_impl('

I am using lexima with no custom configuration.

noahfrederick commented 9 years ago

@smackesey Do you happen to also have https://github.com/tpope/vim-endwise installed? In my case, it seems to be a conflict with that plug-in, as the error goes away when I uninstall endwise.vim or when I load lexima.vim after endwise.vim instead of before.

Here's the output of :verbose imap <CR> when lexima.vim is loaded after endwise.vim (works fine):

i  <CR>        * <C-R>=<SNR>31_map_impl('<CR>', '<CR>')<CR>
        Last set from ~/src/dots/vim/plugged/lexima.vim/autoload/lexima/insmode.vim

And when lexima.vim is loaded first (produces error):

i  <CR>        & <C-R>=<SNR>24_map_impl('<CR>', '<CR>')<CR><SNR>36_DiscretionaryEnd
        Last set from ~/src/dots/vim/plugged/vim-endwise/plugin/endwise.vim
smackesey commented 9 years ago

Indeed I was using endwise and loading it before lexima. I changed the order and now it works fine. Thanks for the pointer!

On Mon, Mar 16, 2015 at 7:56 PM, Noah Frederick notifications@github.com wrote:

@smackesey https://github.com/smackesey Do you happen to also have https://github.com/tpope/vim-endwise installed? In my case, it seems to be a conflict with that plug-in, as the error goes away when I uninstall endwise.vim or when I load lexima.vim after endwise.vim instead of before.

Here's the output of :verbose imap when lexima.vim is loaded after endwise.vim (works fine):

i * =31_map_impl('', '') Last set from ~/src/dots/vim/plugged/lexima.vim/autoload/lexima/insmode.vim

And when lexima.vim is loaded first (produces error):

i & =24_map_impl('', '')36_DiscretionaryEnd Last set from ~/src/dots/vim/plugged/vim-endwise/plugin/endwise.vim

— Reply to this email directly or view it on GitHub https://github.com/cohama/lexima.vim/issues/15#issuecomment-82061846.

noahfrederick commented 9 years ago

No problem. I presume endwise is actually at fault here, though I haven't looked into it yet.

cohama commented 8 years ago

Do you have any problems yet? I will close this issue soon.

smackesey commented 8 years ago

No problems since putting lexima before endwise.