summaryrefslogtreecommitdiff
path: root/compiler/GHC/Tc/Gen
diff options
context:
space:
mode:
Diffstat (limited to 'compiler/GHC/Tc/Gen')
-rw-r--r--compiler/GHC/Tc/Gen/Arrow.hs2
-rw-r--r--compiler/GHC/Tc/Gen/Foreign.hs2
-rw-r--r--compiler/GHC/Tc/Gen/Match.hs6
-rw-r--r--compiler/GHC/Tc/Gen/Pat.hs8
4 files changed, 7 insertions, 11 deletions
diff --git a/compiler/GHC/Tc/Gen/Arrow.hs b/compiler/GHC/Tc/Gen/Arrow.hs
index b404a00b1a..a4eff74ea4 100644
--- a/compiler/GHC/Tc/Gen/Arrow.hs
+++ b/compiler/GHC/Tc/Gen/Arrow.hs
@@ -435,7 +435,7 @@ tcArrDoStmt env ctxt (RecStmt { recS_stmts = L l stmts, recS_later_ids = later_n
-- NB: The rec_ids for the recursive things
-- already scope over this part. This binding may shadow
-- some of them with polymorphic things with the same Name
- -- (see Note [RecStmt] in GHC.Hs.Expr)
+ -- (see Note [How RecStmt works] in Language.Haskell.Syntax.Expr)
; let rec_ids = takeList rec_names tup_ids
; later_ids <- tcLookupLocalIds later_names
diff --git a/compiler/GHC/Tc/Gen/Foreign.hs b/compiler/GHC/Tc/Gen/Foreign.hs
index 53e880c0f6..31f47227c8 100644
--- a/compiler/GHC/Tc/Gen/Foreign.hs
+++ b/compiler/GHC/Tc/Gen/Foreign.hs
@@ -146,7 +146,7 @@ normaliseFfiType' env ty0 = runWriterT $ go Representational initRecTc ty0
| isNewTyCon tc -- Expand newtypes
, Just rec_nts' <- checkRecTc rec_nts tc
- -- See Note [Expanding newtypes] in GHC.Core.TyCon
+ -- See Note [Expanding newtypes and products] in GHC.Core.TyCon.RecWalk
-- We can't just use isRecursiveTyCon; sometimes recursion is ok:
-- newtype T = T (Ptr T)
-- Here, we don't reject the type for being recursive.
diff --git a/compiler/GHC/Tc/Gen/Match.hs b/compiler/GHC/Tc/Gen/Match.hs
index 05d95bf6d2..9c838785ac 100644
--- a/compiler/GHC/Tc/Gen/Match.hs
+++ b/compiler/GHC/Tc/Gen/Match.hs
@@ -546,7 +546,7 @@ tcLcStmt m_tc ctxt (TransStmt { trS_form = form, trS_stmts = stmts
-- Ensure that every old binder of type `b` is linked up with its
-- new binder which should have type `n b`
- -- See Note [GroupStmt binder map] in GHC.Hs.Expr
+ -- See Note [TransStmt binder map] in GHC.Hs.Expr
n_bndr_ids = zipWith mk_n_bndr n_bndr_names bndr_ids
bindersMap' = bndr_ids `zip` n_bndr_ids
@@ -739,7 +739,7 @@ tcMcStmt ctxt (TransStmt { trS_stmts = stmts, trS_bndrs = bindersMap
-- Ensure that every old binder of type `b` is linked up with its
-- new binder which should have type `n b`
- -- See Note [GroupStmt binder map] in GHC.Hs.Expr
+ -- See Note [TransStmt binder map] in GHC.Hs.Expr
n_bndr_ids = zipWithEqual "tcMcStmt" mk_n_bndr n_bndr_names bndr_ids
bindersMap' = bndr_ids `zip` n_bndr_ids
@@ -1005,7 +1005,7 @@ Otherwise the error shows up when checking the rebindable syntax, and
the expected/inferred stuff is back to front (see #3613).
Note [typechecking ApplicativeStmt]
-
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
join ((\pat1 ... patn -> body) <$> e1 <*> ... <*> en)
fresh type variables:
diff --git a/compiler/GHC/Tc/Gen/Pat.hs b/compiler/GHC/Tc/Gen/Pat.hs
index 487b1512ab..45cedcbc8d 100644
--- a/compiler/GHC/Tc/Gen/Pat.hs
+++ b/compiler/GHC/Tc/Gen/Pat.hs
@@ -1402,12 +1402,8 @@ which applies more generally (not just within 'proc'), as it's a good
plan in general to bypass the constraint simplification step entirely
when it's not needed.
-************************************************************************
-* *
- Note [Pattern coercions]
-* *
-************************************************************************
-
+Note [Pattern coercions]
+~~~~~~~~~~~~~~~~~~~~~~~~
In principle, these program would be reasonable:
f :: (forall a. a->a) -> Int