diff options
author | Krzysztof Gogolewski <krzysztof.gogolewski@tweag.io> | 2020-03-10 17:58:32 +0100 |
---|---|---|
committer | Krzysztof Gogolewski <krzysztof.gogolewski@tweag.io> | 2020-03-10 18:05:01 +0100 |
commit | abf5736bcad2d740b5854e2e4a9b3547b9b06639 (patch) | |
tree | 6ce982e8fb785f48fbefcb766890849272d9b415 /compiler/GHC | |
parent | 3300eeacbbf7a3d1f961f809be5d236c48827b28 (diff) | |
download | haskell-abf5736bcad2d740b5854e2e4a9b3547b9b06639.tar.gz |
Typos in comments [skip ci]
Diffstat (limited to 'compiler/GHC')
-rw-r--r-- | compiler/GHC/Core.hs | 6 | ||||
-rw-r--r-- | compiler/GHC/Core/Lint.hs | 4 | ||||
-rw-r--r-- | compiler/GHC/Core/Utils.hs | 2 | ||||
-rw-r--r-- | compiler/GHC/Hs/Decls.hs | 4 | ||||
-rw-r--r-- | compiler/GHC/Hs/Expr.hs | 2 | ||||
-rw-r--r-- | compiler/GHC/Iface/Syntax.hs | 4 | ||||
-rw-r--r-- | compiler/GHC/Iface/Type.hs | 4 |
7 files changed, 13 insertions, 13 deletions
diff --git a/compiler/GHC/Core.hs b/compiler/GHC/Core.hs index 59556fccc2..7a3996364c 100644 --- a/compiler/GHC/Core.hs +++ b/compiler/GHC/Core.hs @@ -783,8 +783,8 @@ is crucial for understanding how case-of-case interacts with join points: "" -> True _ -> False -The simplifier will pull the case into the join point (see Note [Case-of-case -and join points] in Simplify): +The simplifier will pull the case into the join point (see Note [Join points +and case-of-case] in Simplify): join j :: Int -> Bool -> Bool -- changed! @@ -879,7 +879,7 @@ transformation universally. This transformation would do: ===> join go @a n f x = case n of 0 -> case x of True -> e1; False -> e2 - n -> go @a (n-1) f (f x) + n -> go @a (n-1) f (f x) in go @Bool n neg True but that is ill-typed, as `x` is type `a`, not `Bool`. diff --git a/compiler/GHC/Core/Lint.hs b/compiler/GHC/Core/Lint.hs index 091e4d8571..1ebffd7b60 100644 --- a/compiler/GHC/Core/Lint.hs +++ b/compiler/GHC/Core/Lint.hs @@ -840,7 +840,7 @@ lintVarOcc var nargs (text "Non term variable" <+> ppr var) -- See GHC.Core Note [Variable occurrences in Core] - -- Cneck that the type of the occurrence is the same + -- Check that the type of the occurrence is the same -- as the type of the binding site ; ty <- applySubstTy (idType var) ; var' <- lookupIdInScope var @@ -1509,7 +1509,7 @@ lintArrow :: SDoc -> LintedKind -> LintedKind -> LintM LintedKind -- If you edit this function, you may need to update the GHC formalism -- See Note [GHC Formalism] lintArrow what k1 k2 -- Eg lintArrow "type or kind `blah'" k1 k2 - -- or lintarrow "coercion `blah'" k1 k2 + -- or lintArrow "coercion `blah'" k1 k2 = do { unless (classifiesTypeWithValues k1) (addErrL (msg (text "argument") k1)) ; unless (classifiesTypeWithValues k2) (addErrL (msg (text "result") k2)) ; return liftedTypeKind } diff --git a/compiler/GHC/Core/Utils.hs b/compiler/GHC/Core/Utils.hs index 67ff7823e4..07faeee243 100644 --- a/compiler/GHC/Core/Utils.hs +++ b/compiler/GHC/Core/Utils.hs @@ -2322,7 +2322,7 @@ There are some particularly delicate points here: says f=bottom, and replaces the (f `seq` True) with just (f `cast` unsafe-co). BUT, as thing stand, 'f' got arity 1, and it *keeps* arity 1 (perhaps also wrongly). So CorePrep eta-expands - the definition again, so that it does not termninate after all. + the definition again, so that it does not terminate after all. Result: seg-fault because the boolean case actually gets a function value. See #1947. diff --git a/compiler/GHC/Hs/Decls.hs b/compiler/GHC/Hs/Decls.hs index 490113f2eb..b09e0d9eea 100644 --- a/compiler/GHC/Hs/Decls.hs +++ b/compiler/GHC/Hs/Decls.hs @@ -898,9 +898,9 @@ NOTE THAT * The CUSK completely fixes the kind of the type constructor, forever. - * The precise rules, for each declaration form, for whethher a declaration + * The precise rules, for each declaration form, for whether a declaration has a CUSK are given in the user manual section "Complete user-supplied - kind signatures and polymorphic recursion". BUt they simply implement + kind signatures and polymorphic recursion". But they simply implement PRINCIPLE above. * Open type families are interesting: diff --git a/compiler/GHC/Hs/Expr.hs b/compiler/GHC/Hs/Expr.hs index 1f51dccf3d..0c14332d49 100644 --- a/compiler/GHC/Hs/Expr.hs +++ b/compiler/GHC/Hs/Expr.hs @@ -200,7 +200,7 @@ type CmdSyntaxTable p = [(Name, HsExpr p)] -- See Note [CmdSyntaxTable] {- -Note [CmdSyntaxtable] +Note [CmdSyntaxTable] ~~~~~~~~~~~~~~~~~~~~~ Used only for arrow-syntax stuff (HsCmdTop), the CmdSyntaxTable keeps track of the methods needed for a Cmd. diff --git a/compiler/GHC/Iface/Syntax.hs b/compiler/GHC/Iface/Syntax.hs index 719c8bbb48..5c6aeab0e9 100644 --- a/compiler/GHC/Iface/Syntax.hs +++ b/compiler/GHC/Iface/Syntax.hs @@ -777,7 +777,7 @@ pprIfaceDecl ss (IfaceData { ifName = tycon, ifCType = ctype, then isIfaceTauType kind -- Even in the presence of a standalone kind signature, a non-tau -- result kind annotation cannot be discarded as it determines the arity. - -- See Note [Arity inference in kcDeclHeader_sig] in TcHsType + -- See Note [Arity inference in kcCheckDeclHeader_sig] in TcHsType else isIfaceLiftedTypeKind kind) (dcolon <+> ppr kind) @@ -1280,7 +1280,7 @@ noParens pp = pp pprParendIfaceExpr :: IfaceExpr -> SDoc pprParendIfaceExpr = pprIfaceExpr parens --- | Pretty Print an IfaceExpre +-- | Pretty Print an IfaceExpr -- -- The first argument should be a function that adds parens in context that need -- an atomic value (e.g. function args) diff --git a/compiler/GHC/Iface/Type.hs b/compiler/GHC/Iface/Type.hs index 4f8c6571f7..0ff9235d12 100644 --- a/compiler/GHC/Iface/Type.hs +++ b/compiler/GHC/Iface/Type.hs @@ -922,10 +922,10 @@ we do want to turn that (free) r into LiftedRep, so it prints as (forall a. blah) Conclusion: keep track of whether we we are in the kind of a -binder; ohly if so, convert free RuntimeRep variables to LiftedRep. +binder; only if so, convert free RuntimeRep variables to LiftedRep. -} --- | Default 'RuntimeRep' variables to 'LiftedPtr'. e.g. +-- | Default 'RuntimeRep' variables to 'LiftedRep'. e.g. -- -- @ -- ($) :: forall (r :: GHC.Types.RuntimeRep) a (b :: TYPE r). |