Summary
This release is fairly substantial, with a bunch of bug fixes, additional documentation, and a large number of changes and additions to the SML/NJ Library.
Details
Compiler
As part of the fix for bug 220, there has been a change to the way
that "meta" (or "unification") type variables are printed in error
messages. Such meta variables will be represented by type variables
with upper-case letters from the end of the alphabet (e.g., 'X
,
and ''Z
). Overloading constraints are added as a suffix enclosed
in square brackets. For example, the variable ''Z[OL(*)]
has
an equality constraint (denoted by the double quotes and an overload
constraint introduced by an occurrence of the overloaded multiplication
operator. Overload constraints for literals are denoted by WORD
and INT
.
SML/NJ Library
We are in the process of documenting the SML/NJ Library using asciidoctor. As a result of this documentation effort, we have been tweaking the interfaces and implementations of many of the SML/NJ modules, which has resulted in a large number of fairly small changes. The biggest change is the addition of the new UUID Library, but here is the complete list of changes.
-
Added the
disjoint
function to theORD_SET
signature. -
Added more modes to the
ANSITerm
command set. Specifically, we added theDefault
color specifier and the stylesDIM
,NORMAL
,UL_OFF
,BLINK_OFF
,REV_OFF
,INVIS_OFF
, andRESET
. -
Added the structure
FNVHash
to theUtil
library. This structure implements the Fowler-Noll-Vo hashing algorithm. -
Added a new library for generating and manipulating "Universally Unique Identifiers" (
UUID/uuid-lib.cm
). -
Made some changes to the stream processing modules in the JSON library. The return type for the
error
call-back function in theJSONStreamParser.callbacks
type is changed tounit
(note that the function is not expected to return). TheJSONStreamPrinter
implementation now raises theFail
exception when printing is attempted on a closed printer. -
Reimplemented the
find
functions inUnixPath
to use thePathUtil
implementation, rather than reimplementing it. Also changed the result types offindFile
andfindFileOfType
to returnstring option
, instead of raising an exception. -
Added a
QUOTE
constructor to theSExp.value
datatype and cleaned up the details of the syntax of identifiers. Also added acompare
function for theSExp.value
datatype. -
Added operations to the
HashConsSet
andHashConsMap
structures (and corresponding signatures) to bring them inline with theORD_SET
andORD_MAP
interfaces. Also reimplemented these -
Added
insertWith
andinsertWithi
functions to theORD_MAP
signature. -
Replaced the "directional" fold functions (e.g.,
foldl
,foldri
) with non-directional functions (_e.g.,fold
,foldi
) in theHashConsSet
andHashConsMap
structures. The reason for this change is that the order of objects is pretty arbitrary, so there is not any usefulness to processing elements in increasing or decreasing order. For backward compatibility, the old names will continue to work, but they are deprecated amd will be removed in some future release. -
Made the
ControlUtil.Cvt.bool
converter case insensitive. Also, it now allows "yes"/"no" as values. -
Updated the
BitArray:BIT_ARRAY
interface to follow standard patterns (this interfaces was originally designed before the SML Basis Library, so it did not follow the conventions). The changes are to have thefromString
function returnNONE
, instead of raising an exception on bad input, and to use deprecate thelshift
andrshift
operations in favor of>>
and<<
(which useword
for the shift amount). -
Added the
fromVector
,toList
, andtoVector
functions to theDynamicArray:DYNAMIC_ARRAY
interface. -
Renamed the
HASH_SET
signature toMONO_HASH_SET
, which is the correct name given the naming conventions. -
Added
implode
,map
,app
,all
, andexists
functions to theUTF8
signature. Also implemented the handling of 4-byte encodings, which were previously not supported. -
Removed the
version
andbanner
components from theLibBase
structure, since the library has been tracking SML/NJ release versions for a very long time.
Documentation
Additional manual pages have been added for the commands that are part of the standard installation.
Installation
We have updated our infrastructure for building MSI files for Windows to use the latest version of the WiX Toolset. This change should not have any impact on the user-side of the installation process.
32-bit macOS issues
While the x86 installer for 110.97 works on macOs 10.14 Mojave, building from source requires some extra steps because the version of Xcode distributed for Mojave does not include a 32-bit SDK.
Another issue that you may encounter when building on macOs 10.14 Mojave is an error message for a shell script of the form
/bin/sh: bad interpreter: Operation not permitted
This error arises because the com.apple.quarantine
attribute is set on the
shell script. To fix the problem, remove the attribute using the command
xattr -d com.apple.quarantine shell-script
and resume the build.
Bugs
Here is a list of tracked bugs fixed (or closed) with this release, please see the bug tracker for more details.
176 |
Manpages |
195 |
SuccessorML do expression in functor arguments. |
196 |
|
209 |
Special identifiers can be rebound in datatype and exception declarations |
214 |
exception raised by pretty printer in REPL |
220 |
Incorrect error message for equality-type failure? |
239 |
|
240 |
Non-default 64-bit installation build failure |
244 |
Compiler bug: PPObj: ppFields in ppval.sml (also bugs 248 and 255) |
245 |
Lazy data types result in Compiler Bug error (also 249) |
247 |
|
252 |
Boyer Benchmark Compile Failure |
The following unnumbered bug was also fixed:
-
Fixed the calculation of the maximum array/vector length for 64-bit targets.
Supported systems
We believe that SML/NJ will build and run on the following systems, but have only tested some of them:
Architecture | Operating System | Status |
---|---|---|
AMD64 |
FreeBSD 12.0 |
Tested |
macOS 10.14 (Mojave) |
Tested |
|
macOS 10.15 (Catalina) |
Tested |
|
Ubuntu 16.04.3 LTS |
Tested |
|
Ubuntu 18.04.3 LTS |
Tested |
|
|
||
Power PC |
Mac OS X 10.5 (Leopard) |
|
AIX |
||
|
||
Sparc |
Solaris |
|
Linux |
||
|
||
x86 (32-bit) |
Mac OS X 10.6 (Snow Leopard) |
|
Mac OS X 10.7 (Lion) |
||
Mac OS X 10.8 (Mountain Lion) |
||
Mac OS X 10.9 (Mavericks) |
||
Mac OS X 10.10 (Yosemite) |
||
Mac OS X 10.11 (El Capitan) |
||
macOS 10.12 (Sierra) |
Tested |
|
macOS 10.13 (High Sierra) |
Tested |
|
macOS 10.14 (Mojave) |
Tested |
|
Ubuntu 16.04.3 LTS |
Tested |
|
Other Linux variants |
||
FreeBSD 12.0 |
Tested |
|
Other BSD variants |
||
Windows 7 |
||
Windows 10 |
||
Cygwin (32-bit) |
||
|