[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: Re: Problem matching on [.]
- From: "David Burgess" <dburgess@...>
- Date: Tue, 15 May 2007 09:37:55 +1000
What I grapple with is
On 5/15/07, Mark Edgar <email@example.com> wrote:
On 5/14/07, Nick Gammon <firstname.lastname@example.org> wrote:
> I acknowledge that changing Lua to do this may break a whole heap of
> regular expressions currently in use, but perhaps the documentation
> could be clarified to make it clear that a period inside a char-set
> is "itself" and not "all characters".
This could be taken to be an error in PiL, since it disagrees with the
reference manual, which seems pretty clear on this:
"All classes %x described above may also be used as components in set.
All other characters in set represent themselves."
It's my understanding that the reference manual is authoritative,
while PiL is not.
BTW, this is also consistent with traditional regex patterns, where
the pattern [.] also matches a literal dot.