ZyX wrote: > http://code.google.com/p/vim/source/browse/src/ex_docmd.c?r=79c59b4c9d20e5d7de9b5018062289d9a21887e4#2487: > > > #ifdef FEAT_USR_CMDS > > valid_yank_reg(*ea.arg, (ea.cmdidx != CMD_put > > && > > USER_CMDIDX(ea.cmdidx))) > > #else > > Here expression `(ea.cmdidx != CMD_put && USER_CMDIDX(ea.cmdidx))` is > effectively the same thing as `USER_CMDIDX(ea.cmdidx)`. I am not sure what > exactly was meant, but based on the fact that > > yank / > > and > > delete / > > do nothing without any errors and register `/` is excluded from match when > second argument to valid_yank_reg is true I assume this should’ve been > `(ea.cmdidx != CMD_put && !USER_CMDIDX(ea.cmdidx))`: for :put command and > user commands all registers will be valid, for others registers like `/` will > throw an error.
Strange that nobody noticed this before. > Patch without a test (I failed to find any tests for :yank or :delete): Well, perhaps it's about time we have some basic tests.. -- hundred-and-one symptoms of being an internet addict: 267. You get an extra phone line so you can get phone calls. /// Bram Moolenaar -- [email protected] -- 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 [email protected]. For more options, visit https://groups.google.com/d/optout.
