Merge pull request #522 from blueyed/use-vim-current-buffer
VimBuffer: use vim.current.buffer.number instead of vim.eval
This commit is contained in:
commit
5590f9b7be
@ -49,8 +49,8 @@ class VimBuffer(object):
|
||||
|
||||
@property
|
||||
def number(self): # pylint:disable=no-self-use
|
||||
"""The bufnr() of this buffer."""
|
||||
return int(eval("bufnr('%')"))
|
||||
"""The bufnr() of the current buffer."""
|
||||
return vim.current.buffer.number
|
||||
|
||||
@property
|
||||
def cursor(self): # pylint:disable=no-self-use
|
||||
|
Loading…
Reference in New Issue
Block a user