]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
use new "single" compile option
authorGuido van Rossum <guido@python.org>
Mon, 7 Aug 1995 20:16:05 +0000 (20:16 +0000)
committerGuido van Rossum <guido@python.org>
Mon, 7 Aug 1995 20:16:05 +0000 (20:16 +0000)
Lib/pdb.py

index 7a00b83379611ea914444dbceeca4d59d0d78e8f..f44c7e08dda23834709b6b4d003537e5fb5a6fe5 100755 (executable)
@@ -74,8 +74,9 @@ class Pdb(bdb.Bdb, cmd.Cmd):
                locals = self.curframe.f_locals
                globals = self.curframe.f_globals
                globals['__privileged__'] = 1
+               code = compile(line + '\n', '<stdin>', 'single')
                try:
-                       exec(line + '\n', globals, locals)
+                       exec code in globals, locals
                except:
                        if type(sys.exc_type) == type(''):
                                exc_type_name = sys.exc_type