X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=compiler%2Frename%2FRnPat.lhs;h=e56a4ee0d5cb020ba48685edd5fa4829abc50c61;hb=a27c5f77da8b3b3f00f9902b69a504460f234e8c;hp=9d3dc0489ee9151c8d82c5fac9b754cce892ab40;hpb=d51f42f602bf9a6d1b356c41228a534c88723f65;p=ghc-hetmet.git diff --git a/compiler/rename/RnPat.lhs b/compiler/rename/RnPat.lhs index 9d3dc04..e56a4ee 100644 --- a/compiler/rename/RnPat.lhs +++ b/compiler/rename/RnPat.lhs @@ -50,7 +50,6 @@ import HsSyn import TcRnMonad import RnEnv import HscTypes ( availNames ) -import RnNames ( getLocalDeclBinders, extendRdrEnvRn ) import RnTypes ( rnHsTypeFVs, mkOpFormRn, mkOpAppRn, mkNegAppRn, checkSectionPrec, mkConOpPatRn ) @@ -105,14 +104,13 @@ matchNameMaker :: NameMaker matchNameMaker = NM (\ rdr_name thing_inside -> do { names@[name] <- newLocalsRn [rdr_name] - ; bindLocalNamesFV names $ - warnUnusedMatches names $ - thing_inside name }) + ; bindLocalNamesFV names $ do + { (res, fvs) <- thing_inside name + ; warnUnusedMatches names fvs + ; return (res, fvs) }}) topRecNameMaker, localRecNameMaker - :: UniqFM (Located Fixity) -- mini fixity env for the names we're about to bind - -- these fixities need to be brought into scope with the names - -> NameMaker + :: MiniFixityEnv -> NameMaker -- topNameMaker and localBindMaker do not check for unused binding localRecNameMaker fix_env @@ -612,6 +610,6 @@ bogusCharError c = ptext SLIT("character literal out of range: '\\") <> char c <> char '\'' badViewPat pat = vcat [ptext SLIT("Illegal view pattern: ") <+> ppr pat, - ptext SLIT("Use -XViewPatterns to enalbe view patterns")] + ptext SLIT("Use -XViewPatterns to enable view patterns")] \end{code}