diff Lib/idlelib/PyShell.py @ 39782:c94f37054f19

Patch #1550800: make exec a function.
author Georg Brandl <georg@python.org>
date Wed, 06 Sep 2006 06:51:57 +0000
parents 3674f20ac781
children cc992d75d5b3
line wrap: on
line diff
--- a/Lib/idlelib/PyShell.py	Thu Aug 31 21:45:56 2006 +0000
+++ b/Lib/idlelib/PyShell.py	Wed Sep 06 06:51:57 2006 +0000
@@ -690,7 +690,7 @@
         if self.rpcclt:
             self.rpcclt.remotequeue("exec", "runcode", (code,), {})
         else:
-            exec code in self.locals
+            exec(code, self.locals)
         return 1
 
     def runcode(self, code):
@@ -711,7 +711,7 @@
                 elif debugger:
                     debugger.run(code, self.locals)
                 else:
-                    exec code in self.locals
+                    exec(code, self.locals)
             except SystemExit:
                 if not self.tkconsole.closing:
                     if tkMessageBox.askyesno(