12 Jul
2006
12 Jul
'06
3:50 a.m.
hi folks, i'm using ghc6 (apt-get install ghc6) on debian31. as far is i understand, the following program shouldn't crash. can somebody tell me why it does? thanks a lot. johannes. module Main(main) where import Control.Concurrent.STM import System.IO.Unsafe {-# NOINLINE a #-} a :: TMVar Int a = unsafePerformIO $ atomically $ newTMVar 123 main = do atomically $ takeTMVar a >>= putTMVar a ghc --make -fno-cse Test.hs -o test ./test Segmentation fault