'locals' argument of PyEval_EvalCode
- From: Daniel Trstenjak <Daniel.Trstenjak@xxxxxxxxxxxxxxxxxxxx>
- Date: Tue, 28 Nov 2006 14:49:22 +0000 (UTC)
Hi all,
I would like to know the definition of the 'locals' object given to
PyEval_EvalCode. Has 'locals' to be a python dictionary or a subtype
of a python dictionary, or is it enough if the object implements the
necessary protocols?
The python implementation behaves different for the two following code
lines:
from modul import symbol
from modul import *
In the case of the first one, it's enough if the object 'locals' implements
the necessary protocols. The second one only works if the object 'locals'
is a type or subtype of dictionary.
Best Regards,
Daniel
.
- Prev by Date: Re: Question about import and sys.path
- Next by Date: Re: Dynamic/runtime code introspection/compilation
- Previous by thread: Problem with imaplib (weird result if mailbox contains a %)
- Next by thread: Error handling. Python embedded into a C++ app.
- Index(es):