why python annoys me

Moshe Zadka moshez at zadka.site.co.il
Wed Apr 18 01:32:28 EDT 2001


On Tue, 17 Apr 2001 16:38:49 -0700, Paul Prescod <paulp at ActiveState.com> wrote:
 
> It turns out that part of the Python philosophy is that hiding (pseudo-
> or otherwise) isn't really that important and is typically
> counter-productive. I tell people around me not to use it.

Well, anyone using __name for *hiding* is of course out of his rockers.
I use it *a lot*, especially to avoid name-space clashes. That's particularily
useful in mixin classes -- if I need some variable for the method of the
mixin to communicate through, then I often use __name to make sure that
if the main class uses a similarly named variable, we won't clash.

-- 
"I'll be ex-DPL soon anyway so I'm        |LUKE: Is Perl better than Python?
looking for someplace else to grab power."|YODA: No...no... no. Quicker,
   -- Wichert Akkerman (on debian-private)|      easier, more seductive.
For public key, finger moshez at debian.org  |http://www.{python,debian,gnu}.org




More information about the Python-list mailing list