[Haskell-cafe] STM, newArray, and a stack overflow?
Ketil Malde
ketil at malde.org
Wed Mar 23 16:34:59 CET 2011
Bas van Dijk <v.dijk.bas at gmail.com> writes:
Thanks to you and Felipe for trying this out.
>> omap <- atomically $ (newArray_ (0,n-1) :: STM (TArray Int Int))
> I can't reproduce this with ghci-7.0.2 (base-4.3.1.0, array-0.3.0.2
> and stm-2.2.0.1).
It works (calling the same function) from GHCi, but breaks when
compiled. Also when compiling with -O0.
I'm probably doing something wrong, but I can't for the life of me work
out what it might be. I've surrounded the offending newArray with print
statements, so I can't see how it could be something else.
> What version of ghc/ghci are you using?
Happens with GHC 6.12.1 and 7.0.2.
6.12.1, array-0.3.0.0, stm-2.1.1.2
7.0.2, array-0.3.0.2, stm-2.2.0.1
-k
--
If I haven't seen further, it is by standing in the footprints of giants
More information about the Haskell-Cafe
mailing list