BNFC.Regex
Description
Tools to manipulate regular expressions.
nullable :: Reg -> Bool Source #
Check if a regular expression is nullable (accepts the empty string)
simpReg :: Reg -> Reg Source #
Simplification of regular expression, mostly for the purpose of simplifying character alternatives (character classes).
This may help lexer backends, since often lexer generators have a limited syntax for character classes.