flex lexer - lex: default rule for unrecognized strings -
in ocamllex, can utilize _ lexer rule match string not match defined rules, , raise errors. how can accomplish in lex/flex?
typically, define rule this, go @ end:
.|\n { /* process default here */ } this rule match character wasn't matched other rule.
hope helps!
lex flex-lexer
No comments:
Post a Comment