While debugging, use the correct path for breakpoints

This commit is contained in:
Ben Jackson 2020-09-27 21:19:47 +01:00
commit bd09206caf
8 changed files with 203 additions and 8 deletions

View file

@ -268,7 +268,10 @@ class ProjectBreakpoints( object ):
awaiting = awaiting + 1
self._connection.DoRequest(
lambda msg: response_handler( source, msg ),
# The source=source here is critical to ensure that we capture each
# source in the iteration, rather than ending up passing the same source
# to each callback.
lambda msg, source=source: response_handler( source, msg ),
{
'command': 'setBreakpoints',
'arguments': {

View file

@ -119,7 +119,6 @@ class CodeView( object ):
return False
self._current_frame = frame
self._DisplayPC()
if not self._window.valid:
return False
@ -148,6 +147,8 @@ class CodeView( object ):
self.current_syntax = utils.ToUnicode(
vim.current.buffer.options[ 'syntax' ] )
self.ShowBreakpoints()
return True
def Clear( self ):