Mutable counterpart of MaxLengthArray: a branded mutable array type
for arrays with at most MaxLength elements.
Identical to MaxLengthArray except that the structural part is a
mutable Elm[] instead of readonly Elm[], so elements can be reassigned.
The brand is the same, so a MutableMaxLengthArray<M, Elm> is assignable to
MaxLengthArray<M, Elm>.
Note that the MaxLength constraint is not enforced under mutation: pushing
additional elements past the bound is not a type error (as with any mutable
array whose length is tracked only in the brand).
Mutable counterpart of MaxLengthArray: a branded mutable array type for arrays with at most
MaxLengthelements.Identical to MaxLengthArray except that the structural part is a mutable
Elm[]instead ofreadonly Elm[], so elements can be reassigned. The brand is the same, so aMutableMaxLengthArray<M, Elm>is assignable toMaxLengthArray<M, Elm>.Note that the
MaxLengthconstraint is not enforced under mutation: pushing additional elements past the bound is not a type error (as with any mutable array whose length is tracked only in the brand).