
9 Mar
2012
9 Mar
'12
2:39 p.m.
On 2012-03-09 02:13, Johan Tibell wrote:
Hi,
I just ran across some code that calls unsafeThawArray#, writeArray#, and unsafeFreezeArray#, in that order. How unsafe is that?
Quick follow up question: Are unsafeThawArray# and unsafeFreezeArray# guaranteed to not make a copy? I.e. are these two pieces of code equivalent with respect to further usage of the return value: do mary <- unsafeThawArray# ary writeArray# mary 123# newValue unsafeFreezeArray# mary and do mary <- unsafeThawArray# ary writeArray# mary 123# newValue return ary (where do notation is actually done manually.) Twan