[antlr-interest] How to specify ‘any non-control symbol’?
Hendrik Maryns
qwizv9b02 at sneakemail.com
Tue Oct 28 05:36:43 PDT 2008
Hi,
I want to define a LABEL lexer rule which should match almost anything.
Let’s say any non-control Unicode symbol. Antlr wouldn’t accept .* or
.+. I probably don’t want a closing brace in there since it is a
lisp-like grammar, but even space would be fine (although it probably
won’t occur), so I did ~(')')+ but that feels like a hack. Can I use
POSIX regex classes such as p{alphnum} or something of the like?
H.
--
Hendrik Maryns
http://tcl.sfs.uni-tuebingen.de/~hendrik/
==================
Ask smart questions, get good answers:
http://www.catb.org/~esr/faqs/smart-questions.html
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 257 bytes
Desc: OpenPGP digital signature
Url : http://www.antlr.org/pipermail/antlr-interest/attachments/20081028/e78e5a7b/attachment.bin
More information about the antlr-interest
mailing list