Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 22 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
name: Build
on:
push:
pull_request:
# schedule:
# Daily build.
# - cron: '30 8 * * *'
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Get the Repository
uses: actions/checkout@v2

- name: Install latexmk
run: |
sudo apt-get install latexmk texlive-latex-extra -y

- name: Build
run: |
cd definition
latexmk -pdf root
11 changes: 11 additions & 0 deletions .github/workflows/source-checks.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
name: Source Checks
on: [push, pull_request]
jobs:
checks:
runs-on: ubuntu-latest
steps:
- name: Get the Repository
uses: actions/checkout@v2

- name: 'Trailing white spaces ?'
uses: harupy/find-trailing-whitespace@master
55 changes: 26 additions & 29 deletions definition/app1.tex
Original file line number Diff line number Diff line change
Expand Up @@ -79,13 +79,13 @@ \section{Appendix: Derived Forms}
in cases where it would seem clumsy to ``wrap up'' the argument as a
structure expression.
\deletion{\thenostrsharing}{
These forms are currently more experimental than the bare syntax of modules,
These forms are currently more experimental than the bare syntax of modules,
but we recommend implementers to include them so that they can be
tested in practice.
In the derived forms for functor bindings and functor signature expressions,
$\strid$ is a new structure identifier and
the form of $\sigexp'$ depends
on the form of $\sigexp$ as follows.
on the form of $\sigexp$ as follows.
If $\sigexp$ is simply a signature identifier
$\sigid$, then $\sigexp'$ is also $\sigid$; otherwise $\sigexp$ must take
the form ~$\SIG\ \spec_1\ \END$~,
Expand All @@ -102,11 +102,11 @@ \section{Appendix: Derived Forms}
The phrase ``\TYPE\ \typbind'' can be reinterpreted as a type specification that is subject to further transformation.
}
The last derived form for specifications allows sharing between structure
identifiers as a shorthand for type sharing specifications.
%Standard ML no
%longer has a semantic notion of structure sharing;
identifiers as a shorthand for type sharing specifications.
%Standard ML no
%longer has a semantic notion of structure sharing;
%however, for compatability with Standard ML '90, a weaker form
%of structure sharing specification is provided.
%of structure sharing specification is provided.
The phrase
\[
\boxml{$\spec$ sharing $\longstrid_1$ = $\cdots$ = $\longstrid_k$}
Expand All @@ -121,19 +121,19 @@ \section{Appendix: Derived Forms}
\end{array}\]

\noindent
determined as follows.
First, note that $\spec$ specifies a set of
(possibly long) type constructors and structure identifiers, either
directly or via signature identifiers and $\INCLUDE$ specifications.
Then the equivalent form contains all type-sharing constraints
of the form
determined as follows.
First, note that $\spec$ specifies a set of
(possibly long) type constructors and structure identifiers, either
directly or via signature identifiers and $\INCLUDE$ specifications.
Then the equivalent form contains all type-sharing constraints
of the form
\[
\boxml{sharing type $\longstrid_i.\longtycon$ = $\longstrid_j.longtycon$}
\]
$(1\leq i<j\leq k)$, such that both sides of the equation are long type
constructors specified by $\spec$.
$(1\leq i<j\leq k)$, such that both sides of the equation are long type
constructors specified by $\spec$.

The meaning of the derived form does not depend on the order of the
The meaning of the derived form does not depend on the order of the
type-sharing constraints in the equivalent form.


Expand Down Expand Up @@ -375,9 +375,9 @@ \section{Appendix: Derived Forms}
\multicolumn{2}{c}{}\\
%\multicolumn{2}{l}{FUNCTOR BINDINGS \funbind}\\
\multicolumn{2}{l}{{\bf Functor Bindings} \funbind}\\
\cline{1-2}
\cline{1-2}
\mbox{\funid\ \ml{(}\ \spec\ \ml{)}\ $\langle$\ml{:}\ \sigexp$\rangle$\ \ml{=}}&
\mbox{\funid\ \ml{(}\ \strid\ \ml{:} \SIG\ \spec\ \END\ \ml{)}
\mbox{\funid\ \ml{(}\ \strid\ \ml{:} \SIG\ \spec\ \END\ \ml{)}
$\langle$\ml{:}\ $\sigexp'\rangle$\ \ml{=}}\\
\mbox{\ \ \strexp\ $\langle$\AND\ \funbind$\rangle$} &
\mbox{\ \ \LET\ \OPEN\ \strid\ \IN\ \strexp\ \END\ $\langle$\AND\ \funbind$\rangle$} \\
Expand Down Expand Up @@ -415,26 +415,26 @@ \section{Appendix: Derived Forms}
\multicolumn{2}{c}{}\\
%\multicolumn{2}{l}{FUNCTOR BINDINGS \funbind}\\
\multicolumn{2}{l}{{\bf Functor Bindings} \funbind}\\
\cline{1-2}
\cline{1-2}
\mbox{\funid\ \ml{(}\strid\ml{:}\sigexp\ml{)}\ml{:} $\sigexp'$ \ml{=}}&
\mbox{\funid\ \ml{(}\strid\ \ml{:} \sigexp\ml{)} \ \ml{=}}\\
\mbox{\ \ \strexp\ $\langle$\AND\ \funbind$\rangle$} &
\mbox{\ \ \strexp\ml{:}$\sigexp'$\ $\langle$\AND\ \funbind$\rangle$} \\
\cline{1-2}
\cline{1-2}
\mbox{\funid\ \ml{(}\strid\ml{:}\sigexp\ml{)}\ABSTRACT $\sigexp'$ \ml{=}}&
\mbox{\funid\ \ml{(}\strid\ \ml{:} \sigexp\ml{)} \ \ml{=}}\\
\mbox{\ \ \strexp\ $\langle$\AND\ \funbind$\rangle$} &
\mbox{\ \ \strexp\ABSTRACT$\sigexp'$\ $\langle$\AND\ \funbind$\rangle$} \\
\cline{1-2}
\cline{1-2}
\mbox{\funid\ \ml{(}\ \spec\ \ml{)}\ $\langle$\ml{:}\ \sigexp$\rangle$\ \ml{=}}&
\mbox{\funid\ \ml{(}\ $\strid_\nu$\ \ml{:} \SIG\ \spec\ \END\ \ml{)}
\mbox{\funid\ \ml{(}\ $\strid_\nu$\ \ml{:} \SIG\ \spec\ \END\ \ml{)}
\ \ml{=}}\\
\mbox{\ \ \strexp\ $\langle$\AND\ \funbind$\rangle$} &
\mbox{\ \ \LET\ \OPEN\ $\strid_\nu$ \IN\ \strexp$\langle$\ml{:}\ $\sigexp\rangle$}\\
& \mbox{\ \ \END\ $\langle$\AND\ \funbind$\rangle$} \\
\cline{1-2}
\cline{1-2}
\mbox{\funid\ \ml{(}\ \spec\ \ml{)}\ $\langle$\ABSTRACT\ \sigexp$\rangle$\ \ml{=}}&
\mbox{\funid\ \ml{(}\ $\strid_\nu$\ \ml{:} \SIG\ \spec\ \END\ \ml{)}
\mbox{\funid\ \ml{(}\ $\strid_\nu$\ \ml{:} \SIG\ \spec\ \END\ \ml{)}
\ \ml{=}}\\
\mbox{\ \ \strexp\ $\langle$\AND\ \funbind$\rangle$} &
\mbox{\ \ \LET\ \OPEN\ $\strid_\nu$ \IN\ \strexp$\langle$\ABSTRACT $\sigexp\rangle$}\\
Expand All @@ -457,7 +457,7 @@ \section{Appendix: Derived Forms}
\begin{tabular}{|l|l|}
\multicolumn{1}{c}{Derived Form} & \multicolumn{1}{c}{Equivalent Form} \\
\multicolumn{2}{c}{}\\
\multicolumn{2}{l}{{\bf Specifications} \spec}\\
\multicolumn{2}{l}{{\bf Specifications} \spec}\\
\cline{1-2}
\CUT{$\TYPE\;\tyvarseq\;\tycon\,\boxml{=}\,\ty$} & \CUT{\boxml{include}}\\
&\CUT{\boxml{\ sig $\TYPE\;\tyvarseq\;\tycon$}}\\
Expand Down Expand Up @@ -493,13 +493,13 @@ \section{Appendix: Derived Forms}
\multicolumn{2}{r}{\vrule height14pt depth0pt width0pt(see notes in text concerning $\longtycon_{1},\ldots,\longtycon_{m}'$ \ADD{and $\datdesc'$})}\\
%\multicolumn{2}{r}{($n\geq 1$)}\\
\multicolumn{2}{c}{}\\
\multicolumn{2}{l}{\ADD{{\bf Datatype Descriptions} \datdesc}}\\
\multicolumn{2}{l}{\ADD{{\bf Datatype Descriptions} \datdesc}}\\
\cline{1-2}
\ADD{\tyvarseq\ \tycon\ \ml{=} \ml{|} \condesc\ $\langle\AND\ \datdesc\rangle$}
& \ADD{\datdescription} \\
\cline{1-2}
\multicolumn{2}{c}{}\\
\multicolumn{2}{l}{\CUT{{\bf Signature Expressions} \sigexp}}\\
\multicolumn{2}{l}{\CUT{{\bf Signature Expressions} \sigexp}}\\
\cline{1-2}
\CUT{\boxml{$\sigexp$}} & \CUT{\boxml{$\sigexp$}}\\
\CUT{\boxml{where type $\tyvarseq_1\; \longtycon_1$ = $\ty_1$}} & \CUT{\boxml{\ where type $\tyvarseq_1\; \longtycon_1$ = $\ty_1$}}\\
Expand All @@ -511,6 +511,3 @@ \section{Appendix: Derived Forms}
\caption{Derived forms of Specifications \CUT{and Signature Expressions}}
\label{spec-der-forms-fig}
\end{figure}



12 changes: 6 additions & 6 deletions definition/app2.tex
Original file line number Diff line number Diff line change
Expand Up @@ -3,19 +3,19 @@

\section{Appendix: Full Grammar}
\label{core-gram-app}
%In\index{69.1} this Appendix, the full Core
%In\index{69.1} this Appendix, the full Core
%grammar is given for reference purposes.
The full grammar of programs is exactly as given at the start of
The full grammar of programs is exactly as given at the start of
Section~\ref{prog-sec}\FIX{, together with the derived form of
Figure~\ref{functor-der-forms-fig} in Appendix~\ref{derived-forms-app}}.

The\index{69.1} full grammar of Modules consists of the grammar of
The\index{69.1} full grammar of Modules consists of the grammar of
Figures \ref{mod-phr}--\ref{prog-syn} in Section~\ref{syn-mod-sec},
together with the derived forms of \replacement{\thenostrsharing}{Figure~\ref{functor-der-forms-fig}}{Figures~\ref{functor-der-forms-fig} and \ref{spec-der-forms-fig}}
in Appendix~\ref{derived-forms-app}.

The remainder of this Appendix is devoted to the full grammar of the
Core.
Core.
Roughly, it consists of the grammar of Section~\ref{syn-core-sec} augmented by
the derived forms of Appendix~\ref{derived-forms-app}. But there is a further
difference: two additional subclasses of the phrase class ~Exp~ are introduced,
Expand Down Expand Up @@ -65,8 +65,8 @@ \section{Appendix: Full Grammar}

Suppose that the lexical sequence
\[\cdots\ \cdots\ \IF\ \cdots\ \THEN\ \cdots\ \ELSE\ \exp\ \HANDLE\ \cdots\ \cdots\]
is to be parsed, where $\exp$ stands for a lexical sequence which
is already determined as a subphrase (if necessary by applying the
is to be parsed, where $\exp$ stands for a lexical sequence which
is already determined as a subphrase (if necessary by applying the
precedence rule).
Then the higher precedence of $F_2$ (in this case) dictates that $\exp$
associates to the right, i.e. that the correct parse takes the form
Expand Down
12 changes: 6 additions & 6 deletions definition/app3.tex
Original file line number Diff line number Diff line change
Expand Up @@ -10,20 +10,20 @@ \section{Appendix: The Initial Static Basis}
We\index{73.1} shall indicate components of the initial basis by the subscript 0.
The initial static basis is
$\B_0 = \T_0,\F_0,\G_0,\E_0$,
where $F_0 = \emptymap$, $\G_0 = \emptymap$ and
where $F_0 = \emptymap$, $\G_0 = \emptymap$ and
$$\T_0\ =\ \{\BOOL,\INT,\REAL,\STRING,\CHAR,\WORD,\LIST,\FIX{\ARRAY,}\REF,\EXCN\}$$
The members of $\T_0$ are type names, not type constructors; for convenience
we have used type-constructor identifiers
to stand also for the type names which are bound to them in the initial
static type environment $\TE_0$. Of these type names,
\LIST\FIX{, \ARRAY,} and \REF\
have arity 1, the rest have arity 0;
have arity 1, the rest have arity 0;
all except $\EXCN$ \insertion{\thelibrary}{and $\REAL$} admit equality.
Finally, $\E_0 = (\SE_0,\TE_0,\VE_0)$, where $\SE_0 = \emptymap$,
Finally, $\E_0 = (\SE_0,\TE_0,\VE_0)$, where $\SE_0 = \emptymap$,
while $\TE_0$ and $\VE_0$ are shown in Figures~\ref{stat-te} and \ref{stat-ve},
respectively.
}

%\vskip-5mm
\begin{figure}[h]
\begin{center}
Expand All @@ -47,7 +47,7 @@ \section{Appendix: The Initial Static Basis}
\ \atyvar\ast\atyvar\ \LIST
\to\atyvar\ \LIST, \isc)\}\ )$\\
\FIX{\ARRAY} & \FIX{$\mapsto\ (\ \ARRAY$,} & \FIX{$\emptymap\ )$} \\
\REF & $\mapsto\ (\ \REF$, & $\{\REF\mapsto(\forall\ \atyvar\ .\
\REF & $\mapsto\ (\ \REF$, & $\{\REF\mapsto(\forall\ \atyvar\ .\
\atyvar\to\atyvar\ \REF,\isc)\}\ )$\\
\EXCN & $\mapsto\ (\ \EXCN$, & $\emptymap\ )$\\
\hline
Expand All @@ -63,7 +63,7 @@ \section{Appendix: The Initial Static Basis}
\begin{tabular}{|rl|rl|}
\multicolumn{2}{c}{NONFIX}& \multicolumn{2}{c}{INFIX}\\
\hline
$\vid$ & $\mapsto\ (\tych,\is)$
$\vid$ & $\mapsto\ (\tych,\is)$
& $\vid$ & $\mapsto\ (\tych,\is)$\\
\hline
\REF & $\mapsto\ (\forall\ \atyvar\ .\ \atyvar\to\atyvar\ \REF$, \isc)
Expand Down
2 changes: 1 addition & 1 deletion definition/app4.tex
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ \section{Appendix: The Initial Dynamic Basis}
\label{init-dyn-bas-app}
We\index{76.1} shall indicate components of the initial basis by the subscript 0.
\insertion{\thelibrary}
The initial dynamic basis is $\B_0 = \F_0,\G_0,\E_0$,
The initial dynamic basis is $\B_0 = \F_0,\G_0,\E_0$,
where $\F_0 = \emptymap$, $\G_0 = \emptymap$ and $\E_0 = (\SE_0, \TE_0,\VE_0)$,
where $\SE_0 = \emptymap$, $\TE_0$ is shown in Figure~\ref{dynTE0.fig} and
\medskip
Expand Down
30 changes: 15 additions & 15 deletions definition/app5.tex
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ \section{Appendix: The Development of ML}
principally involved. The main emphasis is upon the design of the language;
there is also a section devoted to implementation. On the other hand, no
attempt is made to record work on applications of the language.
\note{\thenewpreface}{This appendix has been revised and extended in
several ways. A detailed list of changes is not available.}
\note{\thenewpreface}{This appendix has been revised and extended in
several ways. A detailed list of changes is not available.}
\subsection*{Origins}

ML and its semantic description have evolved over a period of about
Expand Down Expand Up @@ -95,7 +95,7 @@ \subsection*{Refinement of the Core Language}
description of the I/O mechanism and MacQueen's proposal for program modules
(see later for discussion of this). Since then only few changes to the core
language have occurred. Milner proposed equality types, and these were added,
together with a few minor adjustments~\cite{Mil3}. The
together with a few minor adjustments~\cite{Mil3}. The
last development before the 1990 Definition was in the exception mechanism, by MacQueen using an idea
from Burstall~\cite{AMMT}; it harmonized the ideas of exception and data type
construction.
Expand Down Expand Up @@ -221,7 +221,7 @@ \subsection*{Implementation}

The {\em Standard ML of New Jersey (SML/NJ)} system has been in active development
since 1986~\cite{am87,am91}.
Initially started by David MacQueen at Bell Laboratories and Andrew Appel at Princeton University,
Initially started by David MacQueen at Bell Laboratories and Andrew Appel at Princeton University,
the project has also benefited from significant contributions
by Matthias Blume, Emden Gansner, Lal George, John Reppy and Zhong Shao.
{\em SML/NJ} is a robust and complete environment for Standard ML that supports
Expand All @@ -233,7 +233,7 @@ \subsection*{Implementation}
have contributed to the development of the compiler, in such areas as
efficient closure representations, first-class continuations, type-directed
compilation, concurrent programming, portable code generators, separate
compilation, and register allocation.
compilation, and register allocation.
{\em SML/NJ} has also been widely used to explore extending SML with
concurrency features.

Expand All @@ -248,7 +248,7 @@ \subsection*{Implementation}
%have contributed to the development of the compiler, in such areas as
%efficient closure representations, first-class continuations, type-directed
%compilation, concurrent programming, portable code generators, separate
%compilation, and register allocation.
%compilation, and register allocation.


In 1989, Mads Tofte, Nick Rothwell and David N. Turner started work on the
Expand All @@ -266,7 +266,7 @@ \subsection*{Implementation}
{\em MLWorks} system is a fully-featured graphical programming environment,
including an interactive debugger, inspector, browser, extensive profiling
facilities, separate compilation and delivery, a foreign-language interface,
and libraries for threads and windowing systems.
and libraries for threads and windowing systems.
%Harlequin was a major
%partner in the effort to standardize the revised Standard ML basis library.

Expand Down Expand Up @@ -307,7 +307,7 @@ \subsection*{Implementation}
Rutherford-Appleton Laboratory, by Robert Duncan, Simon Nichols and Aaron
Sloman at the University of Sussex ({\em POPLOG}) and by Malcolm Newey and his
group at the Australian National University.

\subsection*{Semantics}

The description of the first version of ML~\cite{GMW} was informal, and in an
Expand Down Expand Up @@ -359,22 +359,22 @@ \subsection*{Semantics}
\subsection*{Program Libraries}
%During 1989-1991, Dave Berry produced the first program library for
%Standard ML\cite{mllib91,berry93}. Subsequently, a partnership between
%the originators of {\em SML/NJ}, {\em MLWorks} and
%the originators of {\em SML/NJ}, {\em MLWorks} and
%{\em Moscow ML} was formed, with the goal of creating an industrial strength
%initial basis for Standard ML. The resulting SML Basis
%Library\cite{sml-basis-lib} is a much improved and extended
%replacement of the initial basis defined in the 1990 Definition of
%initial basis for Standard ML. The resulting SML Basis
%Library\cite{sml-basis-lib} is a much improved and extended
%replacement of the initial basis defined in the 1990 Definition of
%Standard ML.
During 1989-1991, Dave Berry produced the first program library for
Standard ML\cite{mllib91,berry93}.
The {\em SML/NJ} system is distributed with a rich library organised by
Emden Gansner and John Reppy; this library was the starting point for
the SML Basis Library~.
The {\em SML Basis Library\/}\cite{sml-basis-lib} has been developed
The {\em SML Basis Library\/}\cite{sml-basis-lib} has been developed
over the past three years in a
partnership between the SML/NJ effort, {\em MLWorks}, and {\em Moscow ML}.
The resulting library is a much improved and extended
replacement of the initial basis defined in the 1990 Definition of
The resulting library is a much improved and extended
replacement of the initial basis defined in the 1990 Definition of
Standard ML.

\subsection*{\protect\color{\addcolor} Successor ML}
Expand Down
2 changes: 0 additions & 2 deletions definition/bob.bib
Original file line number Diff line number Diff line change
Expand Up @@ -374,5 +374,3 @@ @Book{Wik
}

}


Loading