[triangle-zpug] how to make import work like execfile() ?
chris.kennedy at coventor.com
Thu Dec 1 20:29:25 CET 2005
Is there an execfile() variant that will load pyc files?
I like execfile() since it makes the code appear to be defind "in place"
in the script and therefore be in the same scope. Using import or from
creates another level of scope.
So I was wondering if a modification to import would make the module
contents by available in the main scope, plus it would work with pyc files.
any ideas? thanks
Chris Kennedy http://www.coventor.com
Product Manager Ph: 919-854-7500 x156
Cary, NC Fx: 919-854-7501
More information about the triangle-zpug