X-Git-Url: http://git.megacz.com/?p=ghc-hetmet.git;a=blobdiff_plain;f=compiler%2Ftypecheck%2FTcMatches.lhs;h=860a6dbd92b0ab79d828a538fafdaea5d2a30416;hp=46b67da9be0db0b97d2bd7c2ac176342933b9fca;hb=e222292914f36f4e42c123a380508f570d5a5f46;hpb=ba05282d3915e7051b3f016366b971a8506b0093 diff --git a/compiler/typecheck/TcMatches.lhs b/compiler/typecheck/TcMatches.lhs index 46b67da..860a6db 100644 --- a/compiler/typecheck/TcMatches.lhs +++ b/compiler/typecheck/TcMatches.lhs @@ -73,7 +73,7 @@ tcMatchesFun fun_name inf matches exp_ty ; checkArgs fun_name matches ; (wrap_gen, (wrap_fun, group)) - <- tcGen (SigSkol (FunSigCtxt fun_name)) exp_ty $ \ _ exp_rho -> + <- tcGen (FunSigCtxt fun_name) exp_ty $ \ _ exp_rho -> -- Note [Polymorphic expected type for tcMatchesFun] matchFunTys herald arity exp_rho $ \ pat_tys rhs_ty -> tcMatches match_ctxt pat_tys rhs_ty matches @@ -104,15 +104,15 @@ tcMatchesCase ctxt scrut_ty matches res_ty tcMatchLambda :: MatchGroup Name -> TcRhoType -> TcM (HsWrapper, MatchGroup TcId) tcMatchLambda match res_ty - = matchFunTys doc n_pats res_ty $ \ pat_tys rhs_ty -> + = matchFunTys herald n_pats res_ty $ \ pat_tys rhs_ty -> tcMatches match_ctxt pat_tys rhs_ty match where n_pats = matchGroupArity match - doc = sep [ ptext (sLit "The lambda expression") - <+> quotes (pprSetDepth (PartWay 1) $ + herald = sep [ ptext (sLit "The lambda expression") + <+> quotes (pprSetDepth (PartWay 1) $ pprMatches (LambdaExpr :: HsMatchContext Name) match), -- The pprSetDepth makes the abstraction print briefly - ptext (sLit "has") <+> speakNOf n_pats (ptext (sLit "argument"))] + ptext (sLit "has")] match_ctxt = MC { mc_what = LambdaExpr, mc_body = tcBody } \end{code}