On Tue, Feb 15, 2022 at 6:13 PM Chris Angelico <ros...@gmail.com> wrote:

> Once upon a time, a "regular expression" was a regular grammar. That is no
> longer the case.
>

I use "regex" for the weird backtracking minilanguages and deliberately
never call them "regular expressions". (I was under the impression that the
Perl documentation observed the same convention but that doesn't seem to be
true.)

Once upon a time, a regular expression could be broadly compatible with
> multiple different parser engines.
>

I think there never was such a time, at least not if you wanted syntactic
compatibility.

Is there any sort of standardization of regexp syntax and semantics[...]?
>

I'm not sure there needs to be. There is no standardization of
programming-language syntax in general, unless you count conventions like
{...} for blocks which Python ignores.

The problem as I see it isn't that the syntax isn't standardized. It's that
the syntax, to the extent it is standardized, is terrible. The only
traditional Unix tool whose regular expression syntax isn't godawful is
lex, and unfortunately that isn't the one that caught on.
_______________________________________________
Python-ideas mailing list -- python-ideas@python.org
To unsubscribe send an email to python-ideas-le...@python.org
https://mail.python.org/mailman3/lists/python-ideas.python.org/
Message archived at 
https://mail.python.org/archives/list/python-ideas@python.org/message/GSYIG5EKDFPD6NOJCS3LXQJVFFGNBMED/
Code of Conduct: http://python.org/psf/codeofconduct/

Reply via email to