Loading ...
Sorry, an error occurred while loading the content.

63037Re: bufnr(" ") fails (always return -1)

Expand Messages
  • Christian Brabandt
    Nov 1, 2011
    • 0 Attachment
      On Mon, October 31, 2011 8:16 pm, Дмитрий Франк wrote:
      > when executing autocommands, bufnr('<afile>') always return -1,
      > bufname('<afile>') returns empty, but expand('<afile>') works.
      >
      > Ugly workaround is to use bufnr(expand('<afile>'))

      I think this is intentionally and no bug.
      bufnr() is not expected to resolve those special variables.

      regards,
      Christian

      --
      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
    • Show all 4 messages in this topic