Making regex suck less
Gerhard Häring
gerhard.haering at gmx.de
Mon Sep 2 01:21:35 EDT 2002
Gerson Kurz wrote in comp.lang.python:
> "A.M. Kuchling" <amk at amk.ca> wrote:
>>The problem with a new syntax is that no one else would be using it, so
>>you'd still need to learn the existing syntax for use with grep, vi, Perl,
>>&c. (It wouldn't surprise me if Perl 6's revised regexes run into this very
>>difficulty and don't gain much adoption.)
>
> A tounge-in-cheek-answer: I don't use grep, I use python. I don't use
> vi,
vi? Yuck. vim or die :-P
> I use python. I don't use perl, I use python :)
>
> Seriously, my thinking was, the re.compile function is there to
> compile an expression to a binary representation for optimized
> searching. So maybe, a "clean syntax" -> "ugly re syntax" compiler
> would be good?
I think it would. Though the other way round wouldn't be that bad,
either.
-- Gerhard
More information about the Python-list
mailing list