private variables/methods
Mel Wilson
mwilson at the-wire.com
Tue Oct 14 10:57:31 EDT 2003
More information about the Python-list mailing list
Tue Oct 14 10:57:31 EDT 2003
- Previous message (by thread): private variables/methods
- Next message (by thread): private variables/methods
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
In article <Iseib.204801$hE5.6891483 at news1.tin.it>, Alex Martelli <aleaxit at yahoo.com> wrote: >Terry Reedy wrote: >>> I think that __current_module__ is perhaps a bit too lengthy >> >> and redundant ;-) > >I disagree. Lengthy it may be, but we do want a 'reserved module >name' to use for this purpose. To me, the existence of a qualified __current_module__.xyz = 3 implies that another local variable can also be called xyz. So we're forced to code things like __current_module__.xyz = 1 - __current_module__.xyz even with all the beautification brackets '__', this starts to look cumbersome to me. I would also prefer (while we're talking about me) that '__' be a hint that we're dealing with wizard code -- overloading standard operators inside class definitions, etc. I don't think I should have to put on my masked avenger tights just to get at my own module-level variables. Maybe Python 3 could re-cast the 'global' keyword to take the place of '__current_module__'. 'module' might be more meaningful, if it doesn't ultimately take one too many useful names away from the programmers. Regards. Mel.
- Previous message (by thread): private variables/methods
- Next message (by thread): private variables/methods
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the Python-list mailing list