[commit: ghc] master: Comments only (4c571f3)
git at git.haskell.org
git at git.haskell.org
Wed Jul 25 16:50:54 UTC 2018
Repository : ssh://git@git.haskell.org/ghc
On branch : master
Link : http://ghc.haskell.org/trac/ghc/changeset/4c571f3321eb8f7a06dada4c37822c22bbdd148b/ghc
>---------------------------------------------------------------
commit 4c571f3321eb8f7a06dada4c37822c22bbdd148b
Author: Simon Peyton Jones <simonpj at microsoft.com>
Date: Wed Jul 25 17:50:28 2018 +0100
Comments only
>---------------------------------------------------------------
4c571f3321eb8f7a06dada4c37822c22bbdd148b
compiler/deSugar/DsBinds.hs | 5 +++--
compiler/typecheck/TcRnTypes.hs | 12 +++++++++---
2 files changed, 12 insertions(+), 5 deletions(-)
diff --git a/compiler/deSugar/DsBinds.hs b/compiler/deSugar/DsBinds.hs
index db7acfd..6524e10 100644
--- a/compiler/deSugar/DsBinds.hs
+++ b/compiler/deSugar/DsBinds.hs
@@ -184,8 +184,9 @@ dsHsBind dflags (AbsBinds { abs_tvs = tyvars, abs_ev_vars = dicts
, abs_binds = binds, abs_sig = has_sig })
= do { ds_binds <- addDictsDs (listToBag dicts) $
dsLHsBinds binds
- -- addDictsDs: push type constraints deeper
- -- for inner pattern match check
+ -- addDictsDs: push type constraints deeper
+ -- for inner pattern match check
+ -- See Check, Note [Type and Term Equality Propagation]
; ds_ev_binds <- dsTcEvBinds_s ev_binds
diff --git a/compiler/typecheck/TcRnTypes.hs b/compiler/typecheck/TcRnTypes.hs
index e8f0762..6627c25 100644
--- a/compiler/typecheck/TcRnTypes.hs
+++ b/compiler/typecheck/TcRnTypes.hs
@@ -385,9 +385,15 @@ instance ContainsModule DsGblEnv where
data DsLclEnv = DsLclEnv {
dsl_meta :: DsMetaEnv, -- Template Haskell bindings
dsl_loc :: RealSrcSpan, -- To put in pattern-matching error msgs
- dsl_dicts :: Bag EvVar, -- Constraints from GADT pattern-matching
- dsl_tm_cs :: Bag SimpleEq,
- dsl_pm_iter :: IORef Int -- no iterations for pmcheck
+
+ -- See Note [Note [Type and Term Equality Propagation] in Check.hs
+ -- These two fields are augmented as we walk inwards,
+ -- through each patttern match in turn
+ dsl_dicts :: Bag EvVar, -- Constraints from GADT pattern-matching
+ dsl_tm_cs :: Bag SimpleEq, -- Constraints form term-level pattern matching
+
+ dsl_pm_iter :: IORef Int -- Number of iterations for pmcheck so far
+ -- We fail if this gets too big
}
-- Inside [| |] brackets, the desugarer looks
More information about the ghc-commits
mailing list