regex - How to recognise start-of-line in an Antlr grammar? -


in language work with, keywords must @ start of line. because string values within language can go on multiple lines, , strings contain these keywords.

the old yacc/lex grammar implementation have deals because lexer uses normal regexes match text patterns, e.g.

^description { actions }

matches 'description' @ start of line , actions.

how can in antlr4? not appear support proper regex lexical matching. i'm using intellij plugin, , complains when use '^' character on lexer rule rhs.


Comments

Popular posts from this blog

1111. appearing after print sequence - php -

node.js - Express and Redis - If session exists for this user, don't allow access -

excel - I can't get the attachement of the email PHP -