Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 6bd6835

Browse files
committed
I've been using gdb a lot lately -- I'm missing 'bt' as a command in
pdb (pdb calls it 'where'). Added 'bt' as an alias for 'where'.
1 parent 663f6c2 commit 6bd6835

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

Lib/pdb.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -450,6 +450,7 @@ def do_clear(self, arg):
450450
def do_where(self, arg):
451451
self.print_stack_trace()
452452
do_w = do_where
453+
do_bt = do_where
453454

454455
def do_up(self, arg):
455456
if self.curindex == 0:
@@ -665,7 +666,9 @@ def help_w(self):
665666
print """w(here)
666667
Print a stack trace, with the most recent frame at the bottom.
667668
An arrow indicates the "current frame", which determines the
668-
context of most commands."""
669+
context of most commands. 'bt' is an alias for this command."""
670+
671+
help_bt = help_w
669672

670673
def help_down(self):
671674
self.help_d()

0 commit comments

Comments
 (0)