V10/cmd/sml/doc/refman/direct.tex

\chapter{Directives}
Directives are included in ML as (syntactically) a subclass of declarations.
They possess scope, as do all declarations.  The directives
\begin{quote}
\verb"infix" {\it d} ${\bf id}_1$ \underline{\ \ \ } ${\bf id}_n$

\verb"infixr" {\it d} ${\bf id}_1$ \underline{\ \ \ } ${\bf id}_n$
\end{quote}
introduce infix status for the identifiers  ${\bf id}_1$  through ${\bf id}_n$.
The digit $d$ (optional, with a default of 0) determines the
precedence, and an infixed identifier associates to the left if
introduced by \verb"infix", and to the right if introduced by
\verb"infixr".  Different infixed operators of equal precedence
associate to the left.  As indicated in Appendix~\ref{grammar}, the precedence
of infixed application is just weaker than that of application.

The directive
\begin{quote}
\verb"nonfix" ${\bf id}_1$ \underline{\ \ \ } ${\bf id}_n$
\end{quote}
cancels infix status for the named identifiers.

While an identifier has infix status, each occurrence of it (as a
value variable or as a constructor) must be infixed or else preceded
by \verb"op".  Note that this includes occurrences of the identifier
within patterns, even binding occurrences of variables.

Several standard functions and constructors have infix status (see
Appendix~\ref{grammar}) with precedence; these are all left associative except
``\verb"::"''.