Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Don't overwrite str object, fix BreakpointWindow (issue #43)

A variable stupidly named `str` was being used, meaning that `str()`
couldn't be used to cast a number to a string. This has been changed,
fixing a problem with the breakpoint window opening.
  • Loading branch information...
commit 3b9b3a23bbdcd30b09b3a40b882349345f640e06 1 parent 7a46982
@joonty authored
Showing with 7 additions and 7 deletions.
  1. +7 −7 plugin/python/vdebug/ui/vimui.py
View
14 plugin/python/vdebug/ui/vimui.py
@@ -349,19 +349,19 @@ def on_create(self):
vim.command('%s | python debugger.runner.ui.breakpointwin.is_open = False' % cmd)
def add_breakpoint(self,breakpoint):
- str = " %-7i | %-11s | " %(breakpoint.id,breakpoint.type)
+ bp_str = " %-7i | %-11s | " %(breakpoint.id,breakpoint.type)
if breakpoint.type == 'line':
- str += "%s:%i" %(breakpoint.file,breakpoint.line)
+ bp_str += "%s:%s" %(breakpoint.file,str(breakpoint.line))
elif breakpoint.type == 'conditional':
- str += "%s:%i when (%s)" \
- %(breakpoint.file,breakpoint.line,breakpoint.condition)
+ bp_str += "%s:%s when (%s)" \
+ %(breakpoint.file,str(breakpoint.line),breakpoint.condition)
elif breakpoint.type == 'exception':
- str += "Exception: %s" % breakpoint.exception
+ bp_str += "Exception: %s" % breakpoint.exception
elif breakpoint.type == 'call' or \
breakpoint.type == 'return':
- str += "Function: %s" % breakpoint.function
+ bp_str += "Function: %s" % breakpoint.function
- self.write(str)
+ self.write(bp_str)
def remove_breakpoint(self,breakpoint_id):
i = 0
Please sign in to comment.
Something went wrong with that request. Please try again.