String.join revisited (URGENT for 1.6)
Aahz Maruch
aahz at netcom.com
Sat Jun 3 10:54:43 EDT 2000
[cc'd to Guido for his delectation upon vacation return]
In article <03062000.1 at sanctum.jae.ddns.org>,
Juergen A. Erhard <jae at ilk.de> wrote:
>
>It would seem (at least to me) to be the nicest (and cleanest) design
>to be able to do:
>
> "some string".split().join()
That's what some people advocate, but that's semantically equivalent to
allowing [].join(). As has been pointed out several times, adding a
join() method to sequence types is a Bad Idea.
So far, nobody has pointed out *ANY* disadvantages of retaining the
current string.join() mechanism, with one exception: it destroys the
"orthogonality" of moving all string functions to string methods. Given
that various people have demonstrated that join() has disadvantages as a
method for both string or sequence types, I think maintaining the 1.5.2
status quo is probably the best option.
--
--- Aahz (Copyright 2000 by aahz at netcom.com)
Androgynous poly kinky vanilla queer het <*> http://www.rahul.net/aahz/
Hugs and backrubs -- I break Rule 6
Have you coined a word today? --Aahz
More information about the Python-list
mailing list