From: simonpj Date: Mon, 4 Apr 2005 16:49:42 +0000 (+0000) Subject: [project @ 2005-04-04 16:49:42 by simonpj] X-Git-Tag: Initial_conversion_from_CVS_complete~814 X-Git-Url: http://git.megacz.com/?a=commitdiff_plain;h=7ea374f542afae31e3758ae9e767a8950a1bb1e0;p=ghc-hetmet.git [project @ 2005-04-04 16:49:42 by simonpj] One more stage2 wibble --- diff --git a/ghc/compiler/hsSyn/Convert.lhs b/ghc/compiler/hsSyn/Convert.lhs index 469a08b..76900dd 100644 --- a/ghc/compiler/hsSyn/Convert.lhs +++ b/ghc/compiler/hsSyn/Convert.lhs @@ -217,11 +217,11 @@ cvt (RecUpdE e flds) = RecordUpd (cvtl e) (map (\(x,y) -> (noLoc (vName x), cvtl placeHolderType placeHolderType cvtHsDo do_or_lc stmts - = HsDo do_or_ld (init stmts') body void + = HsDo do_or_lc (init stmts') body void where - stmts' = cvtstmts ss + stmts' = cvtstmts stmts body = case last stmts' of - L _ (ExprStmt body _) -> body + L _ (ExprStmt body _ _) -> body cvtdecs :: [TH.Dec] -> [HsBindGroup RdrName] cvtdecs [] = [] @@ -283,7 +283,7 @@ cvtguard (GuardedB pairs) = map cvtpair pairs cvtguard (NormalB e) = [noLoc (GRHS [] (cvtl e))] cvtpair :: (TH.Guard,TH.Exp) -> LGRHS RdrName -cvtpair (NormalG x,y) = noLoc (GRHS [nlBindStmt truePat (cvtl x)] +cvtpair (NormalG x,y) = noLoc (GRHS [noLoc $ mkBindStmt truePat (cvtl x)] (cvtl y)) cvtpair (PatG x,y) = noLoc (GRHS (cvtstmts x) (cvtl y))