[5.02] Bug with existentially-quantified constructors
Volker Stolz
vs at foldr.org
Thu Oct 18 11:44:51 EDT 2001
The following program can be compiled using
ghc-5.02 --make test.lhs -fglasgow-exts
but segfaults.
> ./a.out
"foo"
Segmentation fault
\begin{code}
module Main where
import IO
data DS = forall a. C (a -> IO ())
main = do
let (li:st:[]) = [C (print :: String -> IO ()), C (print :: Int -> IO ())]
call li "foo"
call st 3
call (C f) arg = do
f arg
\end{code}
--
Volker Stolz * vs at foldr.org * PGP + S/MIME
More information about the Glasgow-haskell-bugs
mailing list