Node:Syntax Notation,
Next:Sentence,
Previous:Full Syntax,
Up:Full Syntax
Notation
- Syntactic categories (or non-terminals) are written thus:
item. Depending on the section, a category may represent a class
of either terms, token lists, or character strings.
- A syntactic rule takes the general form
C --> F1 | F2 | F3
which states that an entity of category C may take any of the
alternative forms F1, F2, F3, etc.
- Certain definitions and restrictions are given in ordinary English,
enclosed in { } brackets.
- A category written as C... denotes a sequence of one or more
Cs.
- A category written as ?C denotes an optional C.
Therefore ?C... denotes a sequence of zero or more
Cs.
- A few syntactic categories have names with arguments, and rules in which
they appear may contain meta-variables looking thus: X. The meaning
of such rules should be clear from analogy with the definite clause
grammars (see Definite).
- In the section describing the syntax of terms and tokens (see Term Token) particular tokens of the category name are written thus:
name, while tokens which are individual punctuation characters are
written literally.