On 03-Jul-2013 13:17 +0200, Bram Moolenaar wrote: > Ingo Karkat wrote: > >> When inserting text in insert mode via <C-R>, if the expression register >> "= is used, the start of the last changed text somehow gets reset to the >> position where the <C-R>= is triggered; i.e. any previously inserted >> text is not considered as belonging to the current insertion. >> >> vim -N -u NONE >> :let @@ = 'bar' >> :execute "normal! Ofoo\<C-r>\"\<Esc>" >> :echo getpos("'[") >> [0, 1, 1, 0] " Okay. >> >> :execute "normal! Ofoo\<C-r>=v:version\<CR>\<Esc>" >> :echo getpos("'[") >> [0, 1, 1, 0] " Okay: Vim 7.3.712 on Ubuntu 13.04/x64 >> " Okay: Vim 7.3.823 on Windows 7/x64 >> [0, 1, 4, 0] " BUG: Vim 7.3.1280 on Ubuntu 13.04/x64 (huge build) >> >> This regression is breaking plugins and macros; I found it while running >> my plugins' test suites. > > Well, patch 7.3.1253 made CTRL-= start a new insert. Mainly to break > undo, since evaluationg the expression can make unexpected changes.
Ah, I see. That's a good idea, I even go further and have this mapping (but this is just my personal preference): :inoremap <C-R> <C-G>u<C-R> > I suppose we can drop the part of the change that resets the start of > the insert. Thanks, that fixes the problem for me! -- regards, ingo -- -- You received this message from the "vim_dev" maillist. Do not top-post! Type your reply below the text you are replying to. For more information, visit http://www.vim.org/maillist.php --- You received this message because you are subscribed to the Google Groups "vim_dev" group. To unsubscribe from this group and stop receiving emails from it, send an email to vim_dev+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.