
Other regex engines to choose from include PCRE2 and Boost.Regex for Perl and POSIX matching modes. Rule patterns in a lexer specification are converted by the reflex tool to efficient deterministic finite state machines in direct code (option −−fast or in opcode tables −−full.
new methods to analyze ASCII and Unicode input, such as str() and wstr() to obtain the (wide) string match, line() and wline() to obtain the current (wide) line for error reporting. yypush_buffer_state saves the scanner state (line, column, and indentation positions), not just the input buffer. no input buffer length limit (Flex has a 16KB limit). RE/flex offers lots of other practical improvements over Flex++, such as: released under a permissive open source license (BSD-3). other regex engines to choose from, such as PCRE2 and Boost.Regex. regular expressions may contain indent/dedent markers for matching. regular expressions may contain word boundary anchors. regular expressions may contain lazy quantifiers. optional "free space mode" to improve readability of lexer specifications. efficient matching in direct code or with finite state machine tables. options for intuitive customization of the lexer class source code output. generates graphviz files for visualization of finite state machines. generates source code that is easy to understand. easily integrates with Bison reentrant, C++, bridge and location parsers. offers methods for lex/syntax Error reporting and recovery. supports legacy file encoding formats, e.g. fully supports Unicode, auto-detects UTF-8/16/32 with smart input handling. IEEE POSIX P1003.2 standard compliant (like Lex and Flex). accepts Flex/Lex lexer specifications, extended to support Unicode. faster than Flex++ for typical applications such as tokenization. RE/flex is compatible with Bison/Yacc and accepts Flex lexer specifications. RE/flex includes a smart input class to normalize input from files, streams, strings, and memory. RE/flex also includes a fast regex engine written in C++ with options to generate finite state machine tables or direct code to match input more efficiently. RE/flex is the regex-centric, fast lexical analyzer generator with full Unicode support, indentation anchors, lazy quantifiers, word boundaries, and many other modern features. The essential features or qualities of something else." – Oxford Dictionary "Reflex: a thing that is determined by and reproduces "The asteroid to kill this dinosaur is still in orbit." – Lex Manual Registering a handler to support non-blocking reads. Handling old Macintosh files containing CR newlines. Scanning ISO-8859-1 (latin-1) files with a Unicode scanner.
Compilation errors when using yy functions.Errors when declaring extern yyin, yytext, yylineno.