##// END OF EJS Templates
ipdb interface: look up magics by name and call them.
Bradley M. Froehle -
Show More
@@ -478,19 +478,20 b' class Pdb(OldPdb):'
478 """The debugger interface to magic_pdef"""
478 """The debugger interface to magic_pdef"""
479 namespaces = [('Locals', self.curframe.f_locals),
479 namespaces = [('Locals', self.curframe.f_locals),
480 ('Globals', self.curframe.f_globals)]
480 ('Globals', self.curframe.f_globals)]
481 self.shell.magic_pdef(arg, namespaces=namespaces)
481 self.shell.find_line_magic('pdef')(arg, namespaces=namespaces)
482
482
483 def do_pdoc(self, arg):
483 def do_pdoc(self, arg):
484 """The debugger interface to magic_pdoc"""
484 """The debugger interface to magic_pdoc"""
485 namespaces = [('Locals', self.curframe.f_locals),
485 namespaces = [('Locals', self.curframe.f_locals),
486 ('Globals', self.curframe.f_globals)]
486 ('Globals', self.curframe.f_globals)]
487 self.shell.magic_pdoc(arg, namespaces=namespaces)
487 self.shell.find_line_magic('pdoc')(arg, namespaces=namespaces)
488
488
489 def do_pinfo(self, arg):
489 def do_pinfo(self, arg):
490 """The debugger equivalant of ?obj"""
490 """The debugger equivalant of ?obj"""
491 namespaces = [('Locals', self.curframe.f_locals),
491 namespaces = [('Locals', self.curframe.f_locals),
492 ('Globals', self.curframe.f_globals)]
492 ('Globals', self.curframe.f_globals)]
493 self.shell.magic_pinfo("pinfo %s" % arg, namespaces=namespaces)
493 self.shell.find_line_magic('pinfo')("pinfo %s" % arg,
494 namespaces=namespaces)
494
495
495 def checkline(self, filename, lineno):
496 def checkline(self, filename, lineno):
496 """Check whether specified line seems to be executable.
497 """Check whether specified line seems to be executable.
General Comments 0
You need to be logged in to leave comments. Login now