PEG Grammars
← Back to Parser Generators
Parsing Expression Grammars are an alternative to context-free grammars where the choice operator is ordered (try first alternative, fall back to second). PEGs are unambiguous by construction and can be efficiently implemented using packrat parsing with memoization.