[Python-ideas] This seems like a wart to me...
Stephen J. Turnbull
stephen at xemacs.org
Fri Dec 12 09:43:22 CET 2008
Carl Johnson writes:
> the famed saying of Jamie Zawinski ("Some people, when confronted with
> a problem, think 'I know, I'll use regular expressions.' Now they
> have two problems.") is not highly motivating. :-D
Jamie was talking about the "to a man with a hammer, all problems look
like thumbs" phenomenon. I've never heard anybody complain that shell
globs are complex. But regexps will take you a lot farther with just
character classes  (which most modern shells implement), the
wildcard character . (usually ? in shells), and the repetition
operators * and/or + (available only as a variable-length wildcard *
in shell globs).
> > In fact, I personally would like to deprecate the with-argument
> > implementation of string.split(), ....
> > Would that work for you?
> Wouldn't that subtly break the code of everyone who has written
> something like:
Indeed it would. That was not a serious proposal. At this point, I'm
trying to understand the resistence to regexps, not propose an
improvement for .split().
More information about the Python-ideas