mirror of
https://github.com/python/cpython.git
synced 2025-08-31 14:07:50 +00:00
improved prompt format
This commit is contained in:
parent
e23b62f288
commit
a558e37eb4
2 changed files with 13 additions and 5 deletions
|
@ -242,7 +242,7 @@ class Bdb: # Basic Debugger
|
|||
|
||||
#
|
||||
|
||||
def format_stack_entry(self, frame_lineno):
|
||||
def format_stack_entry(self, frame_lineno, lprefix=': '):
|
||||
import linecache, repr, string
|
||||
frame, lineno = frame_lineno
|
||||
filename = frame.f_code.co_filename
|
||||
|
@ -260,7 +260,7 @@ class Bdb: # Basic Debugger
|
|||
s = s + '->'
|
||||
s = s + repr.repr(rv)
|
||||
line = linecache.getline(filename, lineno)
|
||||
if line: s = s + ': ' + string.strip(line)
|
||||
if line: s = s + lprefix + string.strip(line)
|
||||
return s
|
||||
|
||||
# The following two methods can be called by clients to use
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue