| Sent: 20 January 2006 11:00
| To: glasgow-haskell-bugs@haskell.org
| Cc: Simon Peyton-Jones
| Subject: TH bug
|
| Hello ,
|
| attempt to compile this module:
|
| {-# OPTIONS_GHC -fglasgow-exts -fth #-}
| import Language.Haskell.TH
| f = match [p|0|] [|return ()|] []
|
|
| produce the follo
Hello ,
attempt to compile this module:
{-# OPTIONS_GHC -fglasgow-exts -fth #-}
import Language.Haskell.TH
f = match [p|0|] [|return ()|] []
produce the following error:
ghc.EXE: panic! (the `impossible' happened, GHC version 6.4.1):
typecheck/TcSplice.lhs:(128,0)-(150,44): Non-exhaust
I realize that my previous TH programs were incorrect.
But my compiant is about GHC not reporting something like "Multiple
declarations..." but panics or plainly crashes.
Sorry.
___
Glasgow-haskell-bugs mailing list
Glasgow-haskell-bugs@haskell.org
http
If I simply try the following:
{-# OPTIONS -fglasgow-exts #-}
module GenCG where
gdecls pbname pbniname = [d|
valGetter pbname = "Get" ++ pbniname
valSetter pbname = "Set" ++ pbniname
fldGetter pbname = "Get" ++ pbniname ++ "Field"
fldSetter pbname = "Set" ++ pbniname ++ "Field"
arrGetter p
I have the following Haskell modules:
{-# OPTIONS -fglasgow-exts #-}
module GenCG where
gdecls pbname pbniname = [d|
valGetter pbname = "Get" ++ $pbniname
valSetter pbname = "Set" ++ $pbniname
fldGetter pbname = "Get" ++ $pbniname ++ "Field"
fldSetter pbname = "Set" ++ $pbniname ++ "Field"
lift f = lift f
and that gives the infinite loop.
Simon
| -Original Message-
| From: [EMAIL PROTECTED]
[mailto:glasgow-haskell-bugs-
| [EMAIL PROTECTED] On Behalf Of Saswat Anand
| Sent: 19 May 2004 21:05
| To: [EMAIL PROTECTED]
| Subject: TH bug: Lift (a -> b) where
|
| Hello,
|
|
Hello,
I dont know if it has been reported, this looks like a bug in TH. The
program goes into infinite loop.
Saswat
-
instance Lift (a -> b) where
lift f = [| f |]
compile :: (a -> b) -> ExpQ
compile p = lift p
printE :: ExpQ -> IO ()
printE expQ = do exp <- unQ e
: TH bug?
If tried to compile the Print.hs file below (based on the yesterday's
mailing list discussion around the th printf example). I get the following
error message (5.05, MAIN line, Nov 26th build), but I'm not sure if I did
something really silly or if there's a gen
If tried to compile the Print.hs file below (based on the yesterday's mailing list discussion around the th printf example). I get the following error message (5.05, MAIN line, Nov 26th build), but I'm not sure if I did something really silly or if there's a genuine bug in the compiler. Can you pl