From: simonpj Date: Tue, 24 May 2005 09:38:29 +0000 (+0000) Subject: [project @ 2005-05-24 09:38:29 by simonpj] X-Git-Tag: Initial_conversion_from_CVS_complete~480 X-Git-Url: http://git.megacz.com/?a=commitdiff_plain;h=bb8335796f5a6679849f7fae5ad4dcbb717e9755;p=ghc-hetmet.git [project @ 2005-05-24 09:38:29 by simonpj] Yet another wibble to the GHCi top-level interaction story; avoid dup error messages --- diff --git a/ghc/compiler/typecheck/TcRnDriver.lhs b/ghc/compiler/typecheck/TcRnDriver.lhs index 31d832e..66f3f95 100644 --- a/ghc/compiler/typecheck/TcRnDriver.lhs +++ b/ghc/compiler/typecheck/TcRnDriver.lhs @@ -962,7 +962,10 @@ mkPlan (L loc (ExprStmt expr _ _)) -- An expression typed at the prompt -- If not, fail; if so, try to print it. -- The two-step process avoids getting two errors: one from -- the expression itself, and one from the 'print it' part - do { tcGhciStmts [let_stmt]; tcGhciStmts [let_stmt, print_it] } + -- This two-step story is very clunky, alas + do { checkNoErrs (tcGhciStmts [let_stmt]) + --- checkNoErrs defeats the error recovery of let-bindings + ; tcGhciStmts [let_stmt, print_it] } ]} mkPlan stmt@(L loc (BindStmt {}))