Uninitialized UArray - feature or bug?

Simon Marlow simonmar@microsoft.com
Mon, 13 Jan 2003 11:43:57 -0000


> This is a little weird:
>=20
> Prelude> :m + Data.Array.Unboxed
> Prelude Data.Array.Unboxed> let f () =3D array (1, 5) [] ::=20
> UArray Int Int
> Prelude Data.Array.Unboxed> f () =3D=3D f ()
> False
>=20
> Are we giving away purity for efficiency? ;)
> If this behaviour is intended, maybe it should be documented?
>=20
> Maybe it would be a good idea to define default values for types which
> can be unboxed?

That's a very good point :)  Fixed now, thanks.

Cheers,
	Simon