Commit 9be398a5 authored by Simon Peyton Jones's avatar Simon Peyton Jones
Browse files

Reover from validity errors in type/class decls

This lets us report slightly more errors in one sweep
parent df787fa7
......@@ -147,7 +147,11 @@ tcTyClGroup boot_details tyclds
-- expects well-formed TyCons
; tcExtendGlobalEnv tyclss $ do
{ traceTc "Starting validity check" (ppr tyclss)
; mapM_ (addLocM checkValidTyCl) (flattenTyClDecls tyclds)
; mapM_ (recoverM (return ()) . addLocM checkValidTyCl)
(flattenTyClDecls tyclds)
-- We recover, which allows us to report multiple validity errors
-- even from successive groups. But we stop after all groups are
-- processed if we find any errors.
-- Step 4: Add the implicit things;
-- we want them in the environment because
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment