Issue 7196: Clarify str.split() behavior (original ) (raw ) Issue7196
Created on 2009-10-24 04:33 by ggenellina , last changed 2022-04-11 14:56 by admin . This issue is now closed .
Files
File name
Uploaded
Description
Edit
stdtypes.diff
ggenellina,2009-10-24 04:33
Patch against trunk
Messages (3)
msg94401 - (view)
Author: Gabriel Genellina (ggenellina)
Date: 2009-10-24 04:33
Clarify str.split() behavior; see discussion at http:// comments.gmane.org/gmane.comp.python.general/641120
msg99874 - (view)
Author: Jack Diederich (jackdied) *
Date: 2010-02-22 23:30
I suggest this be closed WONTFIX. The str.split() documentation accurately describes str.split() but doesn't happen to do what the OP wanted which was list(filter(None, '00010001'.split('0'))) Instead split(sep) is the reciprocal of sep.join(), that is txt == sep.join(txt.split(sep))
msg99881 - (view)
Author: Raymond Hettinger (rhettinger) *
Date: 2010-02-22 23:51
Agreed. Thanks Jack.
History
Date
User
Action
Args
2022-04-11 14:56:54
admin
set
github: 51445
2010-02-22 23:51:51
rhettinger
set
status: open -> closedresolution: not a bugmessages: +
2010-02-22 23:30:58
jackdied
set
nosy: + jackdied messages: +
2009-10-24 06:05:19
rhettinger
set
assignee: georg.brandl -> rhettinger nosy: + rhettinger
2009-10-24 04:33:41
ggenellina
create