Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Open sidebar
Glasgow Haskell Compiler
GHC
Commits
4c571f33
Commit
4c571f33
authored
Jul 25, 2018
by
Simon Peyton Jones
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Comments only
parent
9897f678
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
12 additions
and
5 deletions
+12
-5
compiler/deSugar/DsBinds.hs
compiler/deSugar/DsBinds.hs
+3
-2
compiler/typecheck/TcRnTypes.hs
compiler/typecheck/TcRnTypes.hs
+9
-3
No files found.
compiler/deSugar/DsBinds.hs
View file @
4c571f33
...
...
@@ -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
...
...
compiler/typecheck/TcRnTypes.hs
View file @
4c571f33
...
...
@@ -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
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a 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