Justin M. Keyes wrote: > Abuse NOTDONE to give some nuance to the return value of readfile(), so > that open_buffer() can distinguish between "general failure" and "failed > because the path is a directory". > > Before this change, Vim *already* creates a new buffer when a directory > is edited. So there's no reason it should not raise BufEnter, that was > an implementation detail of readfile(). > > Most of the changes in this commit merely preserve the old semantics. > The "implicit" change that we actually are interested in, is this line > in `open_buffer()`, where `&retval` being non-FAIL allows EVENT_BUFENTER > to be applied: > > apply_autocmds_retval(EVENT_BUFENTER, NULL, NULL, FALSE, curbuf, &retval); > > Closes #1353
Thanks. I tried writing a test, but since the tests are executed inside a try/catch a new style test doesn't fail even before this patch. -- XML is a nice language for computers. Not for humans. /// 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/d/optout.