diff options
author | Krzysztof Gogolewski <krzysztof.gogolewski@tweag.io> | 2022-04-29 22:37:44 +0200 |
---|---|---|
committer | Marge Bot <ben+marge-bot@smart-cactus.org> | 2022-05-02 18:29:24 -0400 |
commit | 4a7809284354025d07221f0aeca10a7992d23677 (patch) | |
tree | 7cf0ca5525de8d50e6dd4c49a7ec12b50c1ca93e /compiler/GHC/Tc | |
parent | 3e400f204e2b88c501c734f2c4244910ffc0d5dc (diff) | |
download | haskell-4a7809284354025d07221f0aeca10a7992d23677.tar.gz |
Fix several note references
Diffstat (limited to 'compiler/GHC/Tc')
-rw-r--r-- | compiler/GHC/Tc/Gen/Bind.hs | 2 | ||||
-rw-r--r-- | compiler/GHC/Tc/Gen/Export.hs | 10 | ||||
-rw-r--r-- | compiler/GHC/Tc/Gen/Expr.hs | 2 | ||||
-rw-r--r-- | compiler/GHC/Tc/Module.hs | 4 | ||||
-rw-r--r-- | compiler/GHC/Tc/Solver/Interact.hs | 2 | ||||
-rw-r--r-- | compiler/GHC/Tc/TyCl.hs | 2 | ||||
-rw-r--r-- | compiler/GHC/Tc/Utils/Env.hs | 2 |
7 files changed, 12 insertions, 12 deletions
diff --git a/compiler/GHC/Tc/Gen/Bind.hs b/compiler/GHC/Tc/Gen/Bind.hs index 04ff88f7b9..4c5fa5aaa8 100644 --- a/compiler/GHC/Tc/Gen/Bind.hs +++ b/compiler/GHC/Tc/Gen/Bind.hs @@ -1381,7 +1381,7 @@ tcLhs sig_fn no_gen (PatBind { pat_lhs = pat, pat_rhs = grhss }) [ (mbi_poly_name mbi, mbi_mono_id mbi) | mbi <- sig_mbis ] - -- See Note [Existentials in pattern bindings] + -- See Note [Typechecking pattern bindings] ; ((pat', nosig_mbis), pat_ty) <- addErrCtxt (patMonoBindsCtxt pat grhss) $ tcInferFRR FRRPatBind $ \ exp_ty -> diff --git a/compiler/GHC/Tc/Gen/Export.hs b/compiler/GHC/Tc/Gen/Export.hs index 47be72763a..27b2e84d6a 100644 --- a/compiler/GHC/Tc/Gen/Export.hs +++ b/compiler/GHC/Tc/Gen/Export.hs @@ -421,8 +421,7 @@ classifyGREs = partitionGreNames . map gre_name {- Note [Modules without a module header] --------------------------------------------------- - +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ The Haskell 2010 report says in section 5.1: >> An abbreviated form of module, consisting only of the module body, is @@ -523,7 +522,8 @@ lookupChildrenExport spec_parent rdr_items = IncorrectParent p c gs -> failWithDcErr p c gs --- Note: [Typing Pattern Synonym Exports] +-- Note [Typing Pattern Synonym Exports] +-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -- It proved quite a challenge to precisely specify which pattern synonyms -- should be allowed to be bundled with which type constructors. -- In the end it was decided to be quite liberal in what we allow. Below is @@ -567,8 +567,8 @@ lookupChildrenExport spec_parent rdr_items = -- type constructor. -- -- --- Note: [Types of TyCon] --- +-- Note [Types of TyCon] +-- ~~~~~~~~~~~~~~~~~~~~~ -- This check appears to be overly complicated, Richard asked why it -- is not simply just `isAlgTyCon`. The answer for this is that -- a classTyCon is also an `AlgTyCon` which we explicitly want to disallow. diff --git a/compiler/GHC/Tc/Gen/Expr.hs b/compiler/GHC/Tc/Gen/Expr.hs index f85cf4ade5..492c46c7df 100644 --- a/compiler/GHC/Tc/Gen/Expr.hs +++ b/compiler/GHC/Tc/Gen/Expr.hs @@ -676,7 +676,7 @@ tcExpr expr@(RecordUpd { rupd_expr = record_expr, rupd_flds = Left rbnds }) res_ not (isRecordSelector sel_id), let fld_name = idName sel_id ] ; unless (null bad_guys) (sequence bad_guys >> failM) - -- See Note [Mixed Record Selectors] + -- See Note [Mixed Record Field Updates] ; let (data_sels, pat_syn_sels) = partition isDataConRecordSelector sel_ids ; massert (all isPatSynRecordSelector pat_syn_sels) diff --git a/compiler/GHC/Tc/Module.hs b/compiler/GHC/Tc/Module.hs index 9a19461b13..c11639725e 100644 --- a/compiler/GHC/Tc/Module.hs +++ b/compiler/GHC/Tc/Module.hs @@ -1913,7 +1913,7 @@ generateMainBinding tcg_env main_name = do ; (ev_binds, main_expr) <- setMainCtxt main_name io_ty $ tcCheckMonoExpr main_expr_rn io_ty - -- See Note [Root-main id] + -- See Note [Root-main Id] -- Construct the binding -- :Main.main :: IO res_ty = runMainIO res_ty main ; run_main_id <- tcLookupId runMainIOName @@ -1983,7 +1983,7 @@ the moving parts: - check that the export list does indeed export something called 'foo' - generateMainBinding: generate the root-main binding :Main.main = runMainIO M.foo - See Note [Root-main id] + See Note [Root-main Id] An annoying consequence of having both checkMainType and checkMain is that, when (but only when) -fdefer-type-errors is on, we may report an diff --git a/compiler/GHC/Tc/Solver/Interact.hs b/compiler/GHC/Tc/Solver/Interact.hs index 0a246939c6..5adccd835c 100644 --- a/compiler/GHC/Tc/Solver/Interact.hs +++ b/compiler/GHC/Tc/Solver/Interact.hs @@ -2294,7 +2294,7 @@ matchClassInst dflags inerts clas tys loc -- | If a class is "naturally coherent", then we needn't worry at all, in any -- way, about overlapping/incoherent instances. Just solve the thing! -- See Note [Naturally coherent classes] --- See also Note [The equality class story] in "GHC.Builtin.Types.Prim". +-- See also Note [The equality types story] in GHC.Builtin.Types.Prim. naturallyCoherentClass :: Class -> Bool naturallyCoherentClass cls = isCTupleClass cls diff --git a/compiler/GHC/Tc/TyCl.hs b/compiler/GHC/Tc/TyCl.hs index 302f93e691..604740c657 100644 --- a/compiler/GHC/Tc/TyCl.hs +++ b/compiler/GHC/Tc/TyCl.hs @@ -4359,7 +4359,7 @@ checkValidDataCon dflags existential_ok tc con -- matches the type constructor; eg reject this: -- data T a where { MkT :: Bogus a } -- It's important to do this first: - -- see Note [rejigCon + -- see Note [rejigConRes] -- and c.f. Note [Check role annotations in a second pass] -- Check that the return type of the data constructor is an instance diff --git a/compiler/GHC/Tc/Utils/Env.hs b/compiler/GHC/Tc/Utils/Env.hs index 993f458731..b116cbbb29 100644 --- a/compiler/GHC/Tc/Utils/Env.hs +++ b/compiler/GHC/Tc/Utils/Env.hs @@ -1139,7 +1139,7 @@ mkWrapperName wrapperRef what nameBase {- Note [Generating fresh names for FFI wrappers] - +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ We used to use a unique, rather than nextWrapperNum, to distinguish between FFI wrapper functions. However, the wrapper names that we generate are external names. This means that if a call to them ends up |