X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=ghc%2Fcompiler%2FndpFlatten%2FPArrAnal.hs;h=2db56221b24d73be2d310bc8e479fff4f414898d;hb=28a464a75e14cece5db40f2765a29348273ff2d2;hp=0c25805d2c98bbca09aa575753442782b00c31f0;hpb=10fcd78ccde892feccda3f5eacd221c1de75feea;p=ghc-hetmet.git diff --git a/ghc/compiler/ndpFlatten/PArrAnal.hs b/ghc/compiler/ndpFlatten/PArrAnal.hs index 0c25805..2db5622 100644 --- a/ghc/compiler/ndpFlatten/PArrAnal.hs +++ b/ghc/compiler/ndpFlatten/PArrAnal.hs @@ -42,6 +42,7 @@ import TypeRep (Type(..)) import Var (Var(..),Id) import Literal (Literal) import CoreSyn (Expr(..),CoreExpr,Bind(..)) +import PprCore ( {- instances -} ) -- data ArrayUsage = Prim | NonPrim | Array @@ -74,7 +75,7 @@ arrUsage (Let (Rec bnds) expr) = t2 = arrUsage expr in if isArrayUsage t1 then Array else t2 -arrUsage (Case expr b alts) = +arrUsage (Case expr b _ alts) = let t1 = arrUsage expr t2 = scanType (map (arrUsage . (\ (_,_,x) -> x)) alts) @@ -135,8 +136,8 @@ typeArrayUsage (TyConApp tc tcargs) = tcargsAU = map typeArrayUsage tcargs tcCombine = foldr combineArrayUsage Prim tcargsAU in auCon tcCombine -typeArrayUsage t@(SourceTy _) = - pprPanic "PArrAnal.typeArrayUsage: encountered 'SourceType - shouldn't be here!" +typeArrayUsage t@(PredTy _) = + pprPanic "PArrAnal.typeArrayUsage: encountered 'PredType - shouldn't be here!" (ppr t)