[MLton] cvs commit: exposed the types of {Int,Word}{8,16,32,64} using where

Stephen Weeks MLton@mlton.org
Tue, 18 Nov 2003 11:59:24 -0800


> > Using opacity is also problematic, because we would like the
> > following program to fail.
> >
> > structure S:> sig type t end =
> >    struct type t = LargeInt.int end
> > val _ = 0: S.t
> 
> Why is this problematic?

Because we want the opacity to hide the type and disallow overloading
in this case, but when we do Basis2002 :> BASIS_2002 in the basis
library code, we want constant overloading to still work.  Right now
we make it work by adding where clauses that expose the types, but
that exposes sharing that may or may not be correct pending the
discussion on the basis library list.