[vim/vim] autocmd was not fired when open file that name ends with path-sep in `try` (#8885)

9 views
Skip to first unread message

kuuote

unread,
Sep 17, 2021, 11:12:05 AM9/17/21
to vim/vim, Subscribed

Describe the bug
BufEnter autocmd was not fired when open file that name ends with path separator in try block.

To Reproduce
Detailed steps to reproduce the behavior:

  1. Run vim --clean
  2. Sourcing following script.
autocmd BufEnter * echo "foo"
try
  edit /
endtry
  1. foo was not shown.

Expected behavior
autocmd is fire, shows foo.

Environment (please complete the following information):

  • Vim version 8.2.3444
  • OS: Arch Linux
  • Terminal: Alacritty

Additional context
I think it's related sources.

https://github.com/vim/vim/blob/644b49fa0fb90143e8dbe90a7c14c9498d17b266/src/misc2.c
https://github.com/vim/vim/blob/644b49fa0fb90143e8dbe90a7c14c9498d17b266/src/ex_eval.c


You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub.
Triage notifications on the go with GitHub Mobile for iOS or Android.

Bram Moolenaar

unread,
Sep 22, 2021, 8:19:06 AM9/22/21
to vim/vim, Subscribed

Closed #8885 via 40fa12a.

Reply all
Reply to author
Forward
0 new messages