Subj : Re: OO compilers and efficiency To : comp.programming From : Vesa Karvonen Date : Wed Jul 27 2005 11:24 am Jon Harrop wrote: [...] > In OCaml (probably SML too) you can also update record fields which have > been marked "mutable". In fact, a "ref" is nothing more than a record with > a single mutable field: > type 'a ref = { mutable contents: 'a } In SML, ref is primitive and there is no "mutable" keyword. At least the MLton compiler performs ref flattening, which flattens ref cells into their containing objects. See: http://mlton.org/RefFlatten -Vesa Karvonen .