import CoreUnfold ( unfoldingTemplate, hasUnfolding )
import Type ( funResultTy, splitForAllTys, openTypeKind )
import Bag ( isEmptyBag )
-import ErrUtils ( printErrorsAndWarnings, dumpIfSet_dyn, showPass )
+import ErrUtils ( printErrorsAndWarnings, errorsFound, dumpIfSet_dyn, showPass )
import Id ( idType, idUnfolding )
import Module ( Module )
import Name ( Name, toRdrName )
import TyCon ( tyConGenInfo )
import Util
import BasicTypes ( EP(..), Fixity )
-import Bag ( isEmptyBag )
import Outputable
import HscTypes ( PersistentCompilerState(..), HomeSymbolTable,
PackageTypeEnv, ModIface(..),
= do { showPass dflags "Typechecker";
; env <- initTcEnv hst (pcs_PTE pcs)
- ; (maybe_tc_result, (warns,errs)) <- initTc dflags env thing_inside
+ ; (maybe_tc_result, errs) <- initTc dflags env thing_inside
- ; printErrorsAndWarnings unqual (errs,warns)
+ ; printErrorsAndWarnings unqual errs
- ; if isEmptyBag errs then
- return maybe_tc_result
- else
+ ; if errorsFound errs then
return Nothing
+ else
+ return maybe_tc_result
}
\end{code}