Suggestion for a new regular expression extension

Terry Reedy tjreedy at udel.edu
Thu Nov 20 15:23:05 EST 2003


"Nicolas Lehuen" <nicolas.lehuen at thecrmcompany.com> wrote in message
news:mailman.933.1069349900.702.python-list at python.org...
>Well, that's what I am doing now, since I cannot hold my breath until
my
>suggestion gets implemented :).

Probably a looooong wait even if the addition were approved.
The original sre author ceased work a year ago and a substitute
volunteer has worked hard enough to learn the code and fix the bugs.

> But in my case, it forces me to duplicate each alternative
> in the big regexp in my normalisation function,
> which causes quite tedious maintenance of the whole piece of code.

I do not see that.  I believe I would factor out and label the
needed-twice pieces and use ''.join([list-of-pieces]) to make the big
regexp.

> Anyway, I think I'm going to try using sre.Scanner,
> we'll see if it's stable enough for that.

There has been a suggestion on PyDev that the experimental label be
dropped and that it be documented, but it apparently is not clear if
it has been tested enough or is unduplicative enough or if it needs
more work by another volunteer.

Terry J. Reedy






More information about the Python-list mailing list