equal
deleted
inserted
replaced
456 this is a logical type (namely one of class {\tt logic} excluding {\tt |
456 this is a logical type (namely one of class {\tt logic} excluding {\tt |
457 prop}). Otherwise it is $ty$ (note that only the outermost type constructor |
457 prop}). Otherwise it is $ty$ (note that only the outermost type constructor |
458 is taken into account). Finally, the nonterminal of a type variable is {\tt |
458 is taken into account). Finally, the nonterminal of a type variable is {\tt |
459 any}. |
459 any}. |
460 |
460 |
461 \begin{warn} |
461 \begin{warn} |
462 Theories must sometimes declare types for purely syntactic purposes --- |
462 Theories must sometimes declare types for purely syntactic purposes --- |
463 merely playing the role of nonterminals. One example is \tydx{type}, the |
463 merely playing the role of nonterminals. One example is \tydx{type}, the |
464 built-in type of types. This is a `type of all types' in the syntactic |
464 built-in type of types. This is a `type of all types' in the syntactic |
465 sense only. Do not declare such types under {\tt arities} as belonging to |
465 sense only. Do not declare such types under {\tt arities} as belonging to |
466 class {\tt logic}\index{*logic class}, for that would make them useless as |
466 class {\tt logic}\index{*logic class}, for that would make them useless as |
478 production need not map directly to a logical function (this typically |
478 production need not map directly to a logical function (this typically |
479 requires additional syntactic translations, see also |
479 requires additional syntactic translations, see also |
480 Chapter~\ref{chap:syntax}). |
480 Chapter~\ref{chap:syntax}). |
481 |
481 |
482 |
482 |
483 \medskip |
483 \medskip |
484 As a special case of the general mixfix declaration, the form |
484 As a special case of the general mixfix declaration, the form |
485 \begin{center} |
485 \begin{center} |
486 {\tt $c$ ::\ "$\sigma$" ("$template$")} |
486 {\tt $c$ ::\ "$\sigma$" ("$template$")} |
487 \end{center} |
487 \end{center} |
488 specifies no priorities. The resulting production puts no priority |
488 specifies no priorities. The resulting production puts no priority |
489 constraints on any of its arguments and has maximal priority itself. |
489 constraints on any of its arguments and has maximal priority itself. |
490 Omitting priorities in this manner is prone to syntactic ambiguities unless |
490 Omitting priorities in this manner is prone to syntactic ambiguities unless |
491 the production's right-hand side is fully bracketed, as in \verb|"if _ then _ |
491 the production's right-hand side is fully bracketed, as in \verb|"if _ then _ |
558 \begin{description} |
558 \begin{description} |
559 \item[~$d$~] is a delimiter, namely a non-empty sequence of characters |
559 \item[~$d$~] is a delimiter, namely a non-empty sequence of characters |
560 other than the special characters {\tt _}, {\tt(}, {\tt)} and~{\tt/}. |
560 other than the special characters {\tt _}, {\tt(}, {\tt)} and~{\tt/}. |
561 Even these characters may appear if escaped; this means preceding it with |
561 Even these characters may appear if escaped; this means preceding it with |
562 a~{\tt '} (single quote). Thus you have to write {\tt ''} if you really |
562 a~{\tt '} (single quote). Thus you have to write {\tt ''} if you really |
563 want a single quote. Delimiters may never contain spaces. |
563 want a single quote. Furthermore, a~{\tt '} followed by a space separates |
|
564 delimiters without extra white space being added for printing. |
564 |
565 |
565 \item[~{\tt_}~] is an argument position, which stands for a nonterminal symbol |
566 \item[~{\tt_}~] is an argument position, which stands for a nonterminal symbol |
566 or name token. |
567 or name token. |
567 |
568 |
568 \item[~$s$~] is a non-empty sequence of spaces for printing. This and the |
569 \item[~$s$~] is a non-empty sequence of spaces for printing. This and the |