Skip to content

Commit

Permalink
Wipe out scratch buffers
Browse files Browse the repository at this point in the history
Some people are really picky about their buffer numbers and not having
unlisted, unloaded buffers in the buffer list. I personally don't care
and like the fact that marks and stuff are retained between runs, but I
don't care enough to really fight it. This is cleaner afterall.

Closes #879
  • Loading branch information
puremourning committed Nov 16, 2024
1 parent d028fec commit b9ee68b
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions python3/vimspector/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -166,10 +166,9 @@ def CleanUpHiddenBuffer( buf ):
return

try:
vim.command( 'bdelete! {}'.format( buf.number ) )
vim.command( 'bwipeout! {}'.format( buf.number ) )
except vim.error as e:
# FIXME: For now just ignore the "no buffers were deleted" error
if 'E516' not in str( e ):
if 'E517' not in str( e ):
raise


Expand Down

0 comments on commit b9ee68b

Please sign in to comment.