diff --git a/IPython/core/debugger.py b/IPython/core/debugger.py index c8082e3..5964d02 100644 --- a/IPython/core/debugger.py +++ b/IPython/core/debugger.py @@ -640,7 +640,7 @@ class Pdb(OldPdb): """ self.lastcmd = 'list' last = None - if arg: + if arg and arg != ".": try: x = eval(arg, {}, {}) if type(x) == type(()): @@ -655,7 +655,7 @@ class Pdb(OldPdb): except: print('*** Error in argument:', repr(arg), file=self.stdout) return - elif self.lineno is None: + elif self.lineno is None or arg == ".": first = max(1, self.curframe.f_lineno - 5) else: first = self.lineno + 1