You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
grammarware edited this page Jan 20, 2013
·
6 revisions
Nonterminal definitions can be extended (“added to”) vertically and horizontally. In the former case, a given production rule is added to an existing definition. In the latter case (cf. AddH), a given branch is added to a given expression. The horizontal mode is there for convenience only because it could be simulated by a sequence of extraction, vertical addition, and inlining.
There are two operators that are very similar to the vertical add operator: define and introduce. The define operator should be used when an the definition of an undefined nonterminal is added. The introduce operator should be used when a fresh nonterminal is to be defined.
Syntax
[vertical] add:
production
Vertical addition operates on the level of productions: it adds one more production for some nonterminal to any number of productions that are already present in the grammar.