A mutable array with unboxed elements, that can be manipulated in the
ST monad. The type arguments are as follows:
- s: the state variable argument for the ST
type
- i: the index type of the array (should be an instance of
Ix)
- e: the element type of the array. Only certain element
types are supported.
An
STUArray will generally be more efficient (in terms of both
time and space) than the equivalent boxed version (
STArray)
with the same element type. However,
STUArray is strict in its
elements - so don't use
STUArray if you require the
non-strictness that
STArray provides.