parsing expression grammar, aka parsing expression grammar, is a historical grammar language created in 2002. In computer science, a parsing expression grammar, or PEG, is a type of analytic formal grammar, i.e. it describes a formal language in terms of a set of rules for recognizing strings in the language. The formalism was introduced by Bryan Ford in 2004 and is closely related to the family of top-down parsing languages introduced in the early 1970s. Read more on Wikipedia...
- parsing expression grammar ranks in the top 50% of languages
- the parsing expression grammar wikipedia page
- parsing expression grammar first appeared in 2002
- See also: regex
- I have 21 facts about parsing expression grammar. what would you like to know? email me and let me know how I can help.
Example code from the web:
Expr ← Sum Sum ← Product (('+' / '-') Product)* Product ← Value (('*' / '/') Value)* Value ← [0-9]+ / '(' Expr ')'
Example code from Wikipedia:
Value ← [0-9.]+ / '(' Expr ')' Product ← Expr (('*' / '/') Expr)* Sum ← Expr (('+' / '-') Expr)* Expr ← Product / Sum / Value
Last updated October 14th, 2019