From 1eb997a84669f158de9dd16a9e54d279cec22293 Mon Sep 17 00:00:00 2001 From: Takenobu Tani Date: Tue, 9 Jun 2020 22:59:05 +0900 Subject: Clean up haddock hyperlinks of GHC.* (part2) This updates haddock comments only. This patch focuses to update for hyperlinks in GHC API's haddock comments, because broken links especially discourage newcomers. This includes the following hierarchies: - GHC.Iface.* - GHC.Llvm.* - GHC.Rename.* - GHC.Tc.* - GHC.HsToCore.* - GHC.StgToCmm.* - GHC.CmmToAsm.* - GHC.Runtime.* - GHC.Unit.* - GHC.Utils.* - GHC.SysTools.* --- compiler/GHC/Tc/Utils/Backpack.hs | 2 +- compiler/GHC/Tc/Utils/Instantiate.hs | 2 +- compiler/GHC/Tc/Utils/Monad.hs | 2 +- compiler/GHC/Tc/Utils/TcMType.hs | 6 +++--- compiler/GHC/Tc/Utils/TcType.hs | 14 +++++++------- compiler/GHC/Tc/Utils/Unify.hs | 2 +- compiler/GHC/Tc/Utils/Zonk.hs | 4 ++-- 7 files changed, 16 insertions(+), 16 deletions(-) (limited to 'compiler/GHC/Tc/Utils') diff --git a/compiler/GHC/Tc/Utils/Backpack.hs b/compiler/GHC/Tc/Utils/Backpack.hs index 72a1aee55d..f90c6923c8 100644 --- a/compiler/GHC/Tc/Utils/Backpack.hs +++ b/compiler/GHC/Tc/Utils/Backpack.hs @@ -256,7 +256,7 @@ requirementMerges pkgstate mod_name = -- import A -- -- unit q where --- dependency p[A=,B=] +-- dependency p[A=\,B=\] -- signature A -- signature B -- diff --git a/compiler/GHC/Tc/Utils/Instantiate.hs b/compiler/GHC/Tc/Utils/Instantiate.hs index e6f1917331..e7e5c9dc09 100644 --- a/compiler/GHC/Tc/Utils/Instantiate.hs +++ b/compiler/GHC/Tc/Utils/Instantiate.hs @@ -560,7 +560,7 @@ tcSyntaxName :: CtOrigin -> TcM (Name, HsExpr GhcTc) -- ^ (Standard name, suitable expression) -- USED ONLY FOR CmdTop (sigh) *** --- See Note [CmdSyntaxTable] in GHC.Hs.Expr +-- See Note [CmdSyntaxTable] in "GHC.Hs.Expr" tcSyntaxName orig ty (std_nm, HsVar _ (L _ user_nm)) | std_nm == user_nm diff --git a/compiler/GHC/Tc/Utils/Monad.hs b/compiler/GHC/Tc/Utils/Monad.hs index dc7994a62b..c65879a8b4 100644 --- a/compiler/GHC/Tc/Utils/Monad.hs +++ b/compiler/GHC/Tc/Utils/Monad.hs @@ -1519,7 +1519,7 @@ newTcEvBinds = do { binds_ref <- newTcRef emptyEvBindMap , ebv_uniq = uniq }) } -- | Creates an EvBindsVar incapable of holding any bindings. It still --- tracks covar usages (see comments on ebv_tcvs in GHC.Tc.Types.Evidence), thus +-- tracks covar usages (see comments on ebv_tcvs in "GHC.Tc.Types.Evidence"), thus -- must be made monadically newNoTcEvBinds :: TcM EvBindsVar newNoTcEvBinds diff --git a/compiler/GHC/Tc/Utils/TcMType.hs b/compiler/GHC/Tc/Utils/TcMType.hs index d2afbfb4ca..34e4bfe0bb 100644 --- a/compiler/GHC/Tc/Utils/TcMType.hs +++ b/compiler/GHC/Tc/Utils/TcMType.hs @@ -304,7 +304,7 @@ predTypeOccName ty = case classifyPredType ty of -- -- This is monadic to look up the 'TcLclEnv', which is used to initialize -- 'ic_env', and to set the -Winaccessible-code flag. See --- Note [Avoid -Winaccessible-code when deriving] in GHC.Tc.TyCl.Instance. +-- Note [Avoid -Winaccessible-code when deriving] in "GHC.Tc.TyCl.Instance". newImplication :: TcM Implication newImplication = do env <- getLclEnv @@ -609,12 +609,12 @@ tcInstSkolTyVarsAt lvl overlappable subst tvs freshenTyVarBndrs :: [TyVar] -> TcM (TCvSubst, [TyVar]) -- ^ Give fresh uniques to a bunch of TyVars, but they stay -- as TyVars, rather than becoming TcTyVars --- Used in GHC.Tc.Instance.Family.newFamInst, and Inst.newClsInst +-- Used in 'GHC.Tc.Instance.Family.newFamInst', and 'GHC.Tc.Utils.Instantiate.newClsInst' freshenTyVarBndrs = freshenTyCoVars mkTyVar freshenCoVarBndrsX :: TCvSubst -> [CoVar] -> TcM (TCvSubst, [CoVar]) -- ^ Give fresh uniques to a bunch of CoVars --- Used in GHC.Tc.Instance.Family.newFamInst +-- Used in "GHC.Tc.Instance.Family.newFamInst" freshenCoVarBndrsX subst = freshenTyCoVarsX mkCoVar subst ------------------ diff --git a/compiler/GHC/Tc/Utils/TcType.hs b/compiler/GHC/Tc/Utils/TcType.hs index bf6967dccf..280144ac00 100644 --- a/compiler/GHC/Tc/Utils/TcType.hs +++ b/compiler/GHC/Tc/Utils/TcType.hs @@ -7,7 +7,7 @@ {-# LANGUAGE CPP, ScopedTypeVariables, MultiWayIf, FlexibleContexts #-} {-# OPTIONS_GHC -Wno-incomplete-record-updates #-} --- | Types used in the typechecker} +-- | Types used in the typechecker -- -- This module provides the Type interface for front-end parts of the -- compiler. These parts @@ -366,7 +366,7 @@ type TcDTyCoVarSet = DTyCoVarSet ********************************************************************* -} -- | An expected type to check against during type-checking. --- See Note [ExpType] in GHC.Tc.Utils.TcMType, where you'll also find manipulators. +-- See Note [ExpType] in "GHC.Tc.Utils.TcMType", where you'll also find manipulators. data ExpType = Check TcType | Infer !InferResult @@ -417,7 +417,7 @@ mkCheckExpType = Check -- You'll also get three multiplicities back: one for each function arrow. See -- also Note [Linear types] in Multiplicity. -- --- This is defined here to avoid defining it in GHC.Tc.Gen.Expr boot file. +-- This is defined here to avoid defining it in "GHC.Tc.Gen.Expr" boot file. data SyntaxOpType = SynAny -- ^ Any type | SynRho -- ^ A rho type, skolemised or instantiated as appropriate @@ -757,8 +757,8 @@ promoteSkolemsX tclvl = mapAccumL (promoteSkolemX tclvl) -- -- This is important for its use in deciding termination of type -- instances (see #11581). E.g. --- type instance G [Int] = ...(F Int )... --- we don't need to take into account when asking if +-- type instance G [Int] = ...(F Int \)... +-- we don't need to take \ into account when asking if -- the calls on the RHS are smaller than the LHS tcTyFamInsts :: Type -> [(TyCon, [Type])] tcTyFamInsts = map (\(_,b,c) -> (b,c)) . tcTyFamInstsAndVis @@ -1846,7 +1846,7 @@ isImprovementPred ty -- a ~R ...(N a)... -- Not definitely insoluble -- -- Perhaps newtype N a = MkN Int -- See Note [Occurs check error] in --- GHC.Tc.Solver.Canonical for the motivation for this function. +-- "GHC.Tc.Solver.Canonical" for the motivation for this function. isInsolubleOccursCheck :: EqRel -> TcTyVar -> TcType -> Bool isInsolubleOccursCheck eq_rel tv ty = go ty @@ -2104,7 +2104,7 @@ isRigidTy ty -- | Is this type *almost function-free*? See Note [Almost function-free] --- in GHC.Tc.Types +-- in "GHC.Tc.Types" isAlmostFunctionFree :: TcType -> Bool isAlmostFunctionFree ty | Just ty' <- tcView ty = isAlmostFunctionFree ty' isAlmostFunctionFree (TyVarTy {}) = True diff --git a/compiler/GHC/Tc/Utils/Unify.hs b/compiler/GHC/Tc/Utils/Unify.hs index a7787dd4ea..5d7afcf057 100644 --- a/compiler/GHC/Tc/Utils/Unify.hs +++ b/compiler/GHC/Tc/Utils/Unify.hs @@ -775,7 +775,7 @@ tcEqMult origin w_actual w_expected = do %********************************************************************* -} -- | Infer a type using a fresh ExpType --- See also Note [ExpType] in GHC.Tc.Utils.TcMType +-- See also Note [ExpType] in "GHC.Tc.Utils.TcMType" tcInfer :: (ExpSigmaType -> TcM a) -> TcM (a, TcSigmaType) tcInfer tc_check = do { res_ty <- newInferExpType diff --git a/compiler/GHC/Tc/Utils/Zonk.hs b/compiler/GHC/Tc/Utils/Zonk.hs index 8267cb125a..17bdb42c3a 100644 --- a/compiler/GHC/Tc/Utils/Zonk.hs +++ b/compiler/GHC/Tc/Utils/Zonk.hs @@ -29,7 +29,7 @@ module GHC.Tc.Utils.Zonk ( -- * Zonking -- | For a description of "zonking", see Note [What is zonking?] - -- in GHC.Tc.Utils.TcMType + -- in "GHC.Tc.Utils.TcMType" zonkTopDecls, zonkTopExpr, zonkTopLExpr, zonkTopBndrs, ZonkEnv, ZonkFlexi(..), emptyZonkEnv, mkEmptyZonkEnv, initZonkEnv, @@ -203,7 +203,7 @@ the environment manipulation is tiresome. -- Confused by zonking? See Note [What is zonking?] in GHC.Tc.Utils.TcMType. -- | See Note [The ZonkEnv] --- Confused by zonking? See Note [What is zonking?] in GHC.Tc.Utils.TcMType. +-- Confused by zonking? See Note [What is zonking?] in "GHC.Tc.Utils.TcMType". data ZonkEnv -- See Note [The ZonkEnv] = ZonkEnv { ze_flexi :: ZonkFlexi , ze_tv_env :: TyCoVarEnv TyCoVar -- cgit v1.2.1