> 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

Cheers,
Simon

_______________________________________________
Glasgow-haskell-users mailing list
Glasgow-haskell-users@haskell.org
http://www.haskell.org/mailman/listinfo/glasgow-haskell-users

Reply via email to