[−][src]Crate lrlex
lrlex
is a partial replacement for lex
/ flex
. It takes in a .l
file and statically
compiles it to Rust code. The resulting LRNonStreamingLexerDef can then be given an input
string, from which it instantiates an LRNonStreamingLexer. This provides an iterator which
can produce the sequence of lrpar::Lexemes for that input, as well as answer basic queries
about lrpar::Spans (e.g. extracting substrings, calculating line and column numbers).
Macros
lrlex_mod | A convenience macro for including statically compiled |
Structs
LRNonStreamingLexer | An |
LRNonStreamingLexerDef | This struct represents, in essence, a .l file in memory. From it one can produce an LRNonStreamingLexer which actually lexes inputs. |
LexBuildError | Any error from the Lex parser returns an instance of this struct. |
LexerBuilder | A |
Enums
LexErrorKind | The various different possible Lex parser errors. |
LexerKind |
Traits
LexerDef | Methods which all lexer definitions must implement. |
Functions
build_lex | Deprecated |
Type Definitions
LexBuildResult | |
NonStreamingLexerDef | Deprecated |