
13 Nov
2012
13 Nov
'12
7:35 a.m.
On 12/11/2012 16:56, Simon Hengel wrote:
Did you try -fpedantic-bottoms?
I just tried. The exception (or seq?) is still optimized away.
Here is what I tried:
-- file Foo.hs import Control.Exception import Control.DeepSeq main = evaluate (('a' : undefined) `deepseq` return () :: IO ())
$ ghc -fforce-recomp -fpedantic-bottoms -O Foo.hs && ./Foo && echo bar [1 of 1] Compiling Main ( Foo.hs, Foo.o ) Linking Foo ... bar
Sounds like a bug, -fpedantic-bottoms should work here. Please open a ticket. Cheers, Simon