Crate regen

Source
Expand description

§Regen

Regen is a language that defines a language. See README on GitHub

Modules§

core
Core definition of the domain objects that are used to represent the Regen language
dynamic
Utils for dynamically generate AST for source code based on the Language object. Note that this only includes up to the AST, since parse tree hooks cannot be executed dynamically.
emit
Functionality to generate output from the Language struct.
grammar
Generated static implementation of the Regen language, generated by Regen itself
sdk
Generic implementations of functions and objects that are used to parse plain text into application specific objects.

Macros§

impl_union
Generate union implementation for a union rule. Used in generated code.
list
helper for parsing a list of parameters using a TokenStream
merge_list_tail
Util macro to merge first and rest in a parse tree.
merge_list_tail_optional_first
Util macro to merge first and rest in a parse tree.
optional
Helper for parsing an optional parameter using a TokenStream
required
Helper for parsing a required parameter using a TokenStream
sdk
Macro that implements the language SDK.
tree_cast
Convenience macro for casting enum variants for AST and PT.

Functions§

parse_language_from_grammar
Create a language from a grammar string