Crate cfg

Source

Re-exports§

pub use cfg_classify as classify;
pub use cfg_earley as earley;
pub use cfg_generate as generate;
pub use cfg_predict as predict;
pub use cfg_sequence as sequence;

Modules§

binarized_cfg
Binarized rules are rules that have at most two symbols on the right-hand side. A binarized grammar contains only such rules.
cfg
history
precedenced_rule
Precedenced rules are built with the builder pattern.
rhs_closure
rule
This module defines grammar rules. Each rule in a context-free grammar consists of a single symbol on its left-hand side and an array of symbols on its right-hand side. In this library, each rule carries additional value called “history.”
rule_container
symbol

Structs§

BinarizedCfg
Representation for grammars where right-hand sides of all rules have at most two symbols.
Cfg
Basic representation of context-free grammars.
Symbol
A common grammar symbol type.
SymbolSource
A source of numeric symbols.

Enums§

HistoryNode

Traits§

AsRuleRef
Trait for rules of a context-free grammar.
RuleContainer
Trait for rule and symbol containers.

Type Aliases§

HistoryId