X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=compiler%2Ftypecheck%2FTcArrows.lhs;h=4593482c0ed5037209818b09222417e15c4f5273;hb=f16dbbbe59cf3aa19c5fd384560a1b89076d7bc8;hp=082f9da797ba1b3080c53d8c5c2547101d155ed3;hpb=c1500e4888be2341c0b6e6897f494766c86feba0;p=ghc-hetmet.git diff --git a/compiler/typecheck/TcArrows.lhs b/compiler/typecheck/TcArrows.lhs index 082f9da..4593482 100644 --- a/compiler/typecheck/TcArrows.lhs +++ b/compiler/typecheck/TcArrows.lhs @@ -123,8 +123,7 @@ tc_cmd env (HsLet binds (L body_loc body)) res_ty tc_cmd env in_cmd@(HsCase scrut matches) (stk, res_ty) = addErrCtxt (cmdCtxt in_cmd) $ do - (scrut', scrut_ty) <- addErrCtxt (caseScrutCtxt scrut) $ - tcInferRho scrut + (scrut', scrut_ty) <- tcInferRho scrut matches' <- tcMatchesCase match_ctxt scrut_ty matches res_ty return (HsCase scrut' matches') where @@ -341,10 +340,6 @@ arrowTyConKind = mkArrowKinds [liftedTypeKind, liftedTypeKind] liftedTypeKind cmdCtxt :: HsExpr Name -> SDoc cmdCtxt cmd = ptext (sLit "In the command:") <+> ppr cmd -caseScrutCtxt :: LHsExpr Name -> SDoc -caseScrutCtxt cmd - = hang (ptext (sLit "In the scrutinee of a case command:")) 4 (ppr cmd) - nonEmptyCmdStkErr :: HsExpr Name -> SDoc nonEmptyCmdStkErr cmd = hang (ptext (sLit "Non-empty command stack at command:"))