1. Konstantin Lopuhin
  2. pypy

Commits

Philip Jenvey  committed f3626f6

don't lose the cmd line script's filename

  • Participants
  • Parent commits ef3cb0c
  • Branches py3k

Comments (0)

Files changed (1)

File pypy/translator/goal/app_main.py

View file
  • Ignore whitespace
                     def execfile(filename, namespace):
                         with open(filename) as f:
                             code = f.read()
-                        exec_(code, namespace)
+                        exec_(compile(code, filename, 'exec'), namespace)
                     args = (execfile, filename, mainmodule.__dict__)
             success = run_toplevel(*args)