Ka-Ping Yee schrieb:
> On Tue, 29 May 2007, [UTF-8] Ivan Krsti�^G wrote:
>> Guido van Rossum wrote:
>> > What would that do?
 >>
>> It would split on all separators in the tuple, so

Exactly, just like .startswith() with a tuple tries all of the elements.

>>     x.split(("\r", "\n"))
>>
>> would do the same thing that x.splitlines() does now.
> 
> Hmm... would it?  Or should two split points with nothing between
> them produce empty strings, i.e. you would have to do
> 
>     x.split(('\r\n', '\r', '\n'))
> 
> to get the behaviour of x.splitlines()?

Yes, that would be the correct analogon. Sorry, I should have made that
clear.

Georg



-- 
Thus spake the Lord: Thou shalt indent with four spaces. No more, no less.
Four shall be the number of spaces thou shalt indent, and the number of thy
indenting shall be four. Eight shalt thou not indent, nor either indent thou
two, excepting that thou then proceed to four. Tabs are right out.

_______________________________________________
Python-3000 mailing list
Python-3000@python.org
http://mail.python.org/mailman/listinfo/python-3000
Unsubscribe: 
http://mail.python.org/mailman/options/python-3000/archive%40mail-archive.com

Reply via email to