Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
jberryman
GHC
Commits
3370ed76
Commit
3370ed76
authored
Jun 10, 2005
by
simonpj
Browse files
[project @ 2005-06-10 13:33:48 by simonpj]
tcTrace wibble
parent
ae1f585b
Changes
1
Hide whitespace changes
Inline
Side-by-side
ghc/compiler/typecheck/TcRnMonad.lhs
View file @
3370ed76
...
...
@@ -27,7 +27,7 @@ import InstEnv ( emptyInstEnv )
import VarSet ( emptyVarSet )
import VarEnv ( TidyEnv, emptyTidyEnv, emptyVarEnv )
import ErrUtils ( Message, Messages, emptyMessages, errorsFound,
mkWarnMsg, printErrorsAndWarnings,
mkWarnMsg, printErrorsAndWarnings,
pprBagOfErrors,
mkLocMessage, mkLongErrMsg )
import SrcLoc ( mkGeneralSrcSpan, isGoodSrcSpan, SrcSpan, Located(..) )
import NameEnv ( emptyNameEnv )
...
...
@@ -39,10 +39,9 @@ import UniqSupply ( UniqSupply, mkSplitUniqSupply, uniqFromSupply, splitUniqSupp
import Unique ( Unique )
import DynFlags ( DynFlags(..), DynFlag(..), dopt, dopt_set, GhcMode )
import StaticFlags ( opt_PprStyle_Debug )
import Bag ( snocBag, unionBags )
import Bag ( snocBag, unionBags
, unitBag
)
import Panic ( showException )
import Maybe ( isJust )
import IO ( stderr )
import DATA_IOREF ( newIORef, readIORef )
import EXCEPTION ( Exception )
...
...
@@ -432,6 +431,8 @@ addLongErrAt loc msg extra
rdr_env <- getGlobalRdrEnv ;
let { err = mkLongErrMsg loc (unQualInScope rdr_env) msg extra } ;
(warns, errs) <- readMutVar errs_var ;
traceTc (ptext SLIT("Adding error:") <+> \ _ -> pprBagOfErrors (unitBag err)) ;
-- Ugh! traceTc is too specific; unitBag is horrible
writeMutVar errs_var (warns, errs `snocBag` err) }
addErrs :: [(SrcSpan,Message)] -> TcRn ()
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment