Repository : ssh://darcs.haskell.org//srv/darcs/ghc On branch : supercompiler
http://hackage.haskell.org/trac/ghc/changeset/67c7e032fc9c8eedfe0f358c635da8cc946dc77f >--------------------------------------------------------------- commit 67c7e032fc9c8eedfe0f358c635da8cc946dc77f Author: Max Bolingbroke <batterseapo...@hotmail.com> Date: Fri May 11 09:30:03 2012 +0100 Only zap IdInfo for *Id*s >--------------------------------------------------------------- compiler/supercompile/Supercompile/Drive/MSG.hs | 6 +++++- 1 files changed, 5 insertions(+), 1 deletions(-) diff --git a/compiler/supercompile/Supercompile/Drive/MSG.hs b/compiler/supercompile/Supercompile/Drive/MSG.hs index 2a8b0f4..f04f9cb 100644 --- a/compiler/supercompile/Supercompile/Drive/MSG.hs +++ b/compiler/supercompile/Supercompile/Drive/MSG.hs @@ -245,7 +245,7 @@ instance Monad MSG where -- INVARIANT: neither incoming Var may be bound rigidly (rigid only matches against rigid) msgFlexiVar :: RnEnv2 -> Var -> Var -> MSG Var -msgFlexiVar rn2 x_l x_r = msgPend rn2 (zapIdExtraInfo x_r) (PendingVar x_l x_r) +msgFlexiVar rn2 x_l x_r = msgPend rn2 (zapVarExtraInfo x_r) (PendingVar x_l x_r) -- INVARIANT: neither incoming Type can refer to something bound rigidly (can't float out things that reference rigids) msgGeneraliseType :: RnEnv2 -> Type -> Type -> MSG TyVar @@ -277,6 +277,10 @@ msgGeneraliseTerm rn2 e_l e_r = msgPend rn2 x (PendingTerm e_l e_r) Value (Indirect x) -> Just x -- Because we sneakily reuse msgGeneraliseTerm for values as well _ -> Nothing +zapVarExtraInfo :: Var -> Var +zapVarExtraInfo x | isId x = zapIdExtraInfo x + | otherwise = x + zapIdExtraInfo :: Id -> Id zapIdExtraInfo x = mkLocalId (varName x) (idType x) _______________________________________________ Cvs-ghc mailing list Cvs-ghc@haskell.org http://www.haskell.org/mailman/listinfo/cvs-ghc