Type roles for UArray?

wren romano winterkoninkje at gmail.com
Tue Mar 24 13:57:04 UTC 2015


So I was working on porting my libraries to work for GHC 7.10 and I
ran into a snag. Unlike the concrete type Data.Array.Array,  the
concrete type Data.Array.Unboxed.UArray is defined as being nominal in
the second type argument— is this a bug?

If not, then why must it be nominal? Shouldn't (UArray a New) and
(UArray a Old) have the same representation in memory? Using
unsafeCoerce has always been safe here in the past...

-- 
Live well,
~wren


More information about the Libraries mailing list