[path-PEP] Path inherits from basestring again

John Roth newsgroups at jhrothjr.com
Sat Jul 23 19:51:31 EDT 2005


"Reinhold Birkenfeld" <reinhold-birkenfeld-nospam at wolke7.net> wrote in 
message news:3kfpovFu3rt9U1 at individual.net...

>
> I'll look into it. What about iteration and indexing? Should it support
> "for element in path" or "for char in path" or nothing?

I frankly can't think of a use for iterating over the characters in
the path, but I have a number of programs that check elements,
iterate over them and index them (frequently backwards).

I also like to know the number of elements, which seems to make
sense as len(path). Again, the number of characters in the path seems
to be utterly useless information - at least, I can't imagine a use for
it.

John Roth

>
> Reinhold 




More information about the Python-list mailing list