[path-PEP] Path inherits from basestring again
Ivan Van Laningham
ivanlan at pauahtun.org
Fri Jul 29 22:36:57 EDT 2005
Hi All--
Tony Meyer wrote:
>
> So far, there have been various statements that look like +0 for __div__,
> but no-one with a +1. (And I've said this a couple of times now, which
> really is just trolling for a +1 from someone).
>
> > It's not a question of saving characters, but readability which, as
> > you've said, is a matter of opinion.
>
I like / as a shortcut to joinwith(). I like it a lot. I like it so
much I'll give you a +2.
> (Those who are offended by sweeping generalisations should ignore this next
> bit)
>
> I think it's also worth considering that Windows users are more clueless
> than users of posix systems. The readability of __div__ comes from
> familiarity with posix filesystems; for a Windows user, \ would be the
> natural character. So we're making things more readable for users that are
> already more likely figure things out, and less readable for users that have
> trouble figuring things out.
>
This is not only bullshit, it's elitist bullshit. "Windows users are
more clueless than users of posix systems." Pfui. Prove it or withdraw
it.
> 1. ISTM that standard library modules should be as readable as possible,
> even for those that don't use them. If I'm reading the source for module X
> and it uses a Path object, then it should be pretty straightforward to
> understand what is happening without also having to read the Path
> source/docs. This (readability without knowing the language/standard
> libraries) is a huge benefit of using Python.
>
It's overrated. It must be macho to say "I learned Python without
reading books." Next you'll tell me you never ask for directions when
you're lost.
> 2. If I did use the Path module, then I wouldn't use __div__, because it
> looks less readable to me. I suppose I might find that I got annoyed typing
> joinpath, but I doubt it. Also, because I have followed this PEP, I know
> that __div__ means joinwith, so if I read code that used path, I would
> understand it - it's too late for me to try reading code as a 'fresh' user
> and see if it confuses me or not.
>
Then that's your right, but don't try to take / away from people who use
it and like it.
Metta,
Ivan
----------------------------------------------
Ivan Van Laningham
God N Locomotive Works
http://www.andi-holmes.com/
http://www.foretec.com/python/workshops/1998-11/proceedings.html
Army Signal Corps: Cu Chi, Class of '70
Author: Teach Yourself Python in 24 Hours
More information about the Python-list
mailing list