Yukihiro Nakadaira wrote: > On Tue, Dec 31, 2013 at 6:54 PM, Bram Moolenaar <b...@moolenaar.net> wrote: > > > Yukihiro Nakadaira wrote: > > > > > After patch 7.4.045, substitute('xxx', 'x\zs', 'y', 'g') returns "xyxxy". > > > "xyxyxy" is expected. > > > > Thanks for reporting the problem. I'll add it in the todo list. > > > I think that this problem can be fixed with attached patch. > Please check it. > > However, I found another problem, inconsistency between substitute() and :s. > > let y = substitute('aaa', '\ze', 'x', 'g') | $put =y " => xaxaxax > $put ='aaa' | s/\ze/x/g " => xaxaxa > > let y = substitute('abc', 'a\|\ze', 'x', 'g') | $put =y " => xxbxcx > $put ='abc' | s/a\|\ze/x/g " => xbxc
Nice to see a patch for this problem. -- Microsoft says that MS-Windows is much better for you than Linux. That's like the Pope saying that catholicism is much better for you than protestantism. /// Bram Moolenaar -- b...@moolenaar.net -- http://www.Moolenaar.net \\\ /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ \\\ an exciting new programming language -- http://www.Zimbu.org /// \\\ help me help AIDS victims -- http://ICCF-Holland.org /// -- -- 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.