Re: [Python-Dev] str.strip() enhancement

2005-09-03 Thread Raymond Hettinger
> > Even if an example or two is found, it is worth complicating the API. > > Keep in mind the difficulties that plague str.split() -- that is what > > happens when a function grows beyond a single, clear, unified, > > cohesive > > concept. > > I am not aware of these difficulties, any pointers?

Re: [Python-Dev] str.strip() enhancement

2005-09-03 Thread Jonny Reichwald
Raymond Hettinger wrote: > [Jonny Reichwald] >> Would this be useful for anyone else besides me? > > Probably not. ok > Even if an example or two is found, it is worth complicating the API. > Keep in mind the difficulties that plague str.split() -- that is what > happens when a function grows b

Re: [Python-Dev] str.strip() enhancement

2005-09-03 Thread Josiah Carlson
"Raymond Hettinger" <[EMAIL PROTECTED]> wrote: > > [Jonny Reichwald] > > I would like to suggest a small enhancement to str.strip(). > > By expanding its current form, where it only takes a char list, to > > taking any list containing either char lists or string lists, it is > > possible to remov

Re: [Python-Dev] str.strip() enhancement

2005-09-03 Thread Raymond Hettinger
[Jonny Reichwald] > I would like to suggest a small enhancement to str.strip(). > By expanding its current form, where it only takes a char list, to > taking any list containing either char lists or string lists, it is > possible to remove entire words from the stripped string. . . . > Would this

[Python-Dev] str.strip() enhancement

2005-09-03 Thread Jonny Reichwald
Hi, I would like to suggest a small enhancement to str.strip(). By expanding its current form, where it only takes a char list, to taking any list containing either char lists or string lists, it is possible to remove entire words from the stripped string. To clarify what I mean, here are som