The examples with Bison require the installation of Bison.
json.l
JSON parser (validated against http://seriot.ch/parsing_json.php)ctokens.l
andcdefs.l
a C/C++ tokenizerjtokens.l
andjdefs.l
a Java tokenizer, meets Java Lexical Structure requirementsecho.l
classic interactive scanner to echo inputreadline.l
interactive scanner to echo input using readline(3)yyscanstrings.l
demonstrates string and buffer scanningwc.l
word count examplewcu.l
word count example with Unicode matching (RE/flex only)wcpp.l
word count example with lexer class variableswcwc.l
word count example with custom lexer classflexexample1.l
example taken from the Flex documentationflexexample2.l
example from http://matt.might.net/articles/standalone-lexers-with-lexflexexample3.l
example from the Flex documentation with C bisonflexexample3.lxx
example from the Flex documentation with C++ bisonflexexample4.l
example from the Flex documentation with C bison-bridgeflexexample4.lxx
example from the Flex documentation with C++ bison-bridgeflexexample5.l
example from the Flex documentation with C bison-bridgeflexexample5.lxx
example from the Flex documentation with C++ bison-bridgeflexexample6.l
example reentrant scanner with state stacksflexexample7.l
example from the Flex documentation with C bison-locationsflexexample7.lxx
example from the Flex documentation with C++ bison-locationsflexexample8.l
example from the Flex documentation with C bison-bridge and bison-locationsflexexample8.lxx
example from the Flex documentation with C++ bison-bridge and bison-locationsflexexample9.lxx
example Bison 3.0 %skeleton "lalr1.cc" C++ parser with bison-cc and bison-locationsflexexample10.l
example from the Flex documentation to use multiple buffers
braille.l
a braille translator, inspired by the re2c example but expanded and fixed to make it useableptokens.l
andpdefs.l
a Python tokenizercalc.l
andcalc.y
calculator, supports Unicode identifier variables, resolves input errorscow.l
scanner to convert cowscows.l
scanner to convert cows, uses word boundary anchorscsv.l
scanner to parse CSV rows from a file into a C++ vectorindent1.l
indentation detection and reformatting example, basicindent2.l
indentation detection and reformatting example, advanced with start conditionsunicode.l
a very simple Unicode word matcher to demonstrate Unicode matchingscanstrings.l
demonstrates string and buffer scanningmmap.l
demonstrates mmap(2) to scan C/C++ source code files fastgz.l
demonstrates scanning zlib-compressed (and uncompressed) C/C++ source code filesdos.l
demonstrates scanning DOS-formatted files withreflex::BufferedInput::dos_streambuf
fastfind.l
demonstrates fast search for patterns in input, rather than scanning the inputtag.l
simple lexer to print out all XML/HTML tagstag_lazy.l
simple lexer to print XML/HTML tags, uses lazy quantstag_lazystates.l
lexer to print XML tags, uses lazy quants and statestag_unicode.l
lexer to print XML tags, uses lazy quants and states, checks UTF-8 validitytag_tidy.l
lexer to tidy and normalize HTMLreflexexample3.l
example RE/flex scanner adapted from the Flex documentation with C bisonreflexexample3.lxx
example RE/flex scanner adapted from the Flex documentation with C++ bisonreflexexample4.l
example RE/flex scanner adapted from the Flex documentation with C bison-bridgereflexexample4.lxx
example RE/flex scanner adapted from the Flex documentation with C++ bison-bridgereflexexample5.l
example RE/flex scanner adapted from the Flex documentation with C bison-bridgereflexexample5.lxx
example RE/flex scanner adapted from the Flex documentation with C++ bison-bridgereflexexample6.l
example RE/flex reentrant scanner with state stacksreflexexample7.l
example RE/flex scanner adapted from the Flex documentation with C bison-locationsreflexexample7.lxx
example RE/flex scanner adapted from the Flex documentation with C++ bison-locationsreflexexample8.l
example RE/flex scanner adapted from the Flex documentation with C bison-bridge and bison-locationsreflexexample8.lxx
example RE/flex scanner adapted from the Flex documentation with C++ bison-bridge and bison-locationsreflexexample9.lxx
example RE/flex scanner with Bison 3.0 %skeleton "lalr1.cc" C++ parser with bison-cc and bison-locationsreflexexample10.l
example RE/flex scanner adapted from the Flex documentation to use multiple buffersreflexexample11.lxx
example RE/flex scanner with Bison 3.2 C++ parser with bison-complete and bison-locations
cards.cpp
matches credit card numberscvt2utf
demonstratesreflex::Input
UTF-8 normalization to convert files to UTF-8/16/32fastsearch.cpp
demonstrates super fast search with fixed regex patterns, faster than GNU grepugrep.cpp
universal grep to search files fast, uses the RE/flex regex engineurl.cpp
capture domain, path, and query keys from URLs (requires Boost.Regex for captures)