global myfunc; def myfunc():
Bruce Dodson
bruce_dodson at bigfoot.com
Wed Jul 28 23:49:56 EDT 1999
More information about the Python-list mailing list
Wed Jul 28 23:49:56 EDT 1999
- Previous message (by thread): global myfunc; def myfunc():
- Next message (by thread): global myfunc; def myfunc():
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
I have noticed that, when using python as an embedded language in another program, using a temporary dictionary for a private namespace, and using __main__'s dictionary for my global namespace, I can say: global myfunc def myfunc(): ... to bind myfunc into the global namespace, which allows it to persist across calls. But I want to make sure that is "intended behavior" and not just some implementation quirk, so I can decide whether to document that as a feature. Any advice? Thanx, Bruce
- Previous message (by thread): global myfunc; def myfunc():
- Next message (by thread): global myfunc; def myfunc():
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the Python-list mailing list