Lonnie Princehouse <[EMAIL PROTECTED]> wrote:
...
> @namespace # indicates function should be executed in namespace
> def initialize_namespace():
> x = 5
>
> # versus the alternative
>
> __namespace__ = {
> 'x' : 5,
> }
Hm, what about:
ns = namespace(x=5)
and perhaps later
ns.update(y=6)
if you need to add a name to ns? You can start with 'namespace=dict'
(in whatever ubernamespace you'd define your @namespace decorator above)
and change it later in any way you wish -- and it's vastly less
blackmagical, too.
Alex
--
http://mail.python.org/mailman/listinfo/python-list