Commit 7b4c7b75 authored by Brian Wignall's avatar Brian Wignall

Fix typos

parent c14b723f
Pipeline #13152 passed with stages
in 505 minutes and 9 seconds
......@@ -559,7 +559,7 @@ idIsFrom mod id = nameIsLocalOrFrom mod (idName id)
{- Note [Levity-polymorphic Ids]
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Some levity-polymorphic Ids must be applied and and inlined, not left
Some levity-polymorphic Ids must be applied and inlined, not left
un-saturated. Example:
unsafeCoerceId :: forall r1 r2 (a::TYPE r1) (b::TYPE r2). a -> b
......
......@@ -171,7 +171,7 @@ transCloVarSet :: (VarSet -> VarSet)
-- The function fn could be (Var -> VarSet), but we use (VarSet -> VarSet)
-- for efficiency, so that the test can be batched up.
-- It's essential that fn will work fine if given new candidates
-- one at at time; ie fn {v1,v2} = fn v1 `union` fn v2
-- one at a time; ie fn {v1,v2} = fn v1 `union` fn v2
-- Use fixVarSet if the function needs to see the whole set all at once
transCloVarSet fn seeds
= go seeds seeds
......@@ -334,7 +334,7 @@ transCloDVarSet :: (DVarSet -> DVarSet)
-- The function fn could be (Var -> DVarSet), but we use (DVarSet -> DVarSet)
-- for efficiency, so that the test can be batched up.
-- It's essential that fn will work fine if given new candidates
-- one at at time; ie fn {v1,v2} = fn v1 `union` fn v2
-- one at a time; ie fn {v1,v2} = fn v1 `union` fn v2
transCloDVarSet fn seeds
= go seeds seeds
where
......
......@@ -195,7 +195,7 @@ switchTargetsToTable (SwitchTargets _ (lo,hi) mbdef branches)
-- .quad _c20q
-- .quad _c20r
-- | The list of all labels occuring in the SwitchTargets value.
-- | The list of all labels occurring in the SwitchTargets value.
switchTargetsToList :: SwitchTargets -> [Label]
switchTargetsToList (SwitchTargets _ _ mbdef branches)
= maybeToList mbdef ++ M.elems branches
......
......@@ -210,7 +210,7 @@ exprsSomeFreeVarsDSet :: InterestingVarFun -- ^ Says which 'Var's are interestin
exprsSomeFreeVarsDSet fv_cand e =
fvDVarSet $ filterFV fv_cand $ mapUnionFV expr_fvs e
-- Comment about obselete code
-- Comment about obsolete code
-- We used to gather the free variables the RULES at a variable occurrence
-- with the following cryptic comment:
-- "At a variable occurrence, add in any free variables of its rule rhss
......
......@@ -87,7 +87,7 @@ allocateGlobalBinder name_supply mod occ loc
-- of the Name, so we set this field in the Name we return.
--
-- Then (bogus) multiple bindings of the same Name
-- get different SrcLocs can can be reported as such.
-- get different SrcLocs can be reported as such.
--
-- Possible other reason: it might be in the cache because we
-- encountered an occurrence before the binding site for an
......
......@@ -242,7 +242,7 @@ runLink dflags args = traceToolCommand dflags "linker" $ do
--
-- `-optl` args come at the end, so that later `-l` options
-- given there manually can fill in symbols needed by
-- Haskell libaries coming in via `args`.
-- Haskell libraries coming in via `args`.
linkargs <- neededLinkArgs `fmap` getLinkerInfo dflags
let (p,args0) = pgm_l dflags
optl_args = map Option (getOpts dflags opt_l)
......
......@@ -359,7 +359,7 @@ takeL n (BlockChain blks) =
-- While we could take into account the space between the two blocks which
-- share an edge this blows up compile times quite a bit. It requires
-- us to find all edges between two chains, check the distance for all edges,
-- rank them based on the distance and and only then we can select two chains
-- rank them based on the distance and only then we can select two chains
-- to combine. Which would add a lot of complexity for little gain.
--
-- So instead we just rank by the strength of the edge and use the first pair we
......@@ -891,4 +891,3 @@ lookupDeleteUFM :: Uniquable key => UniqFM elt -> key
lookupDeleteUFM m k = do -- Maybe monad
v <- lookupUFM m k
return (v, delFromUFM m k)
......@@ -855,7 +855,7 @@ leftIdentityDynFlags id_lit = do
return e2
-- | Left identity rule for PrimOps like 'IntAddC' and 'WordAddC', where, in
-- addition to the result, we have to indicate that no carry/overflow occurred.
leftIdentityCDynFlags :: (DynFlags -> Literal) -> RuleM CoreExpr
leftIdentityCDynFlags id_lit = do
dflags <- getDynFlags
......@@ -872,7 +872,7 @@ rightIdentityDynFlags id_lit = do
return e1
-- | Right identity rule for PrimOps like 'IntSubC' and 'WordSubC', where, in
-- addition to the result, we have to indicate that no carry/overflow occurred.
rightIdentityCDynFlags :: (DynFlags -> Literal) -> RuleM CoreExpr
rightIdentityCDynFlags id_lit = do
dflags <- getDynFlags
......@@ -886,7 +886,7 @@ identityDynFlags lit =
leftIdentityDynFlags lit `mplus` rightIdentityDynFlags lit
-- | Identity rule for PrimOps like 'IntAddC' and 'WordAddC', where, in addition
-- to the result, we have to indicate that no carry/overflow occured.
-- to the result, we have to indicate that no carry/overflow occurred.
identityCDynFlags :: (DynFlags -> Literal) -> RuleM CoreExpr
identityCDynFlags lit =
leftIdentityCDynFlags lit `mplus` rightIdentityCDynFlags lit
......
......@@ -92,7 +92,7 @@ mode changes, this triggers a recompilation from that module in the dependcy
graph. So we can just worry mostly about direct imports.
There is one trust property that can change for a package though without
recompliation being triggered: package trust. So we must check that all
recompilation being triggered: package trust. So we must check that all
packages a module tranitively depends on to be trusted are still trusted when
we are compiling this module (as due to recompilation avoidance some modules
below may not be considered trusted any more without recompilation being
......
......@@ -777,7 +777,7 @@ Exammples:
It's controlled by a flag (floatConsts), because doing this too
early loses opportunities for RULES which (needless to say) are
important in some nofib programs (gcd is an example). [SPJ note:
I think this is obselete; the flag seems always on.]
I think this is obsolete; the flag seems always on.]
Note [Floating join point bindings]
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
......
......@@ -558,7 +558,7 @@ discarding the arguments to zip. Usually this is fine, but on the
LHS of a rule it's not, because 'as' and 'bs' are now not bound on
the LHS.
This is a pretty pathalogical example, so I'm not losing sleep over
This is a pretty pathological example, so I'm not losing sleep over
it, but the simplest solution was to check sm_inline; if it is False,
which it is on the LHS of a rule (see updModeForRules), then don't
make use of the strictness info for the function.
......
......@@ -412,7 +412,7 @@ goodToLift dflags top_lvl rec_flag expander pairs scope = decide
is_memoized_rhs StgRhsCon{} = True
is_memoized_rhs (StgRhsClosure _ _ upd _ _) = isUpdatable upd
-- Don't lift binders occuring as arguments. This would result in complex
-- Don't lift binders occurring as arguments. This would result in complex
-- argument expressions which would have to be given a name, reintroducing
-- the very allocation at each call site that we wanted to get rid off in
-- the first place.
......
......@@ -576,7 +576,7 @@ Hence, the invariant is this:
************************************************************************
-}
-- | Specialise calls to type-class overloaded functions occuring in a program.
-- | Specialise calls to type-class overloaded functions occurring in a program.
specProgram :: ModGuts -> CoreM ModGuts
specProgram guts@(ModGuts { mg_module = this_mod
, mg_rules = local_rules
......@@ -2107,7 +2107,7 @@ Consider
We gather the call info for (f @T $df), and we don't want to drop it
when we come across the binding for $df. So we add $df to the floats
and continue. But then we have to add $c== to the floats, and so on.
These all float above the binding for 'f', and and now we can
These all float above the binding for 'f', and now we can
successfully specialise 'f'.
So the DictBinds in (ud_binds :: Bag DictBind) may contain
......
......@@ -342,7 +342,7 @@ tcLocalBinds (HsIPBinds x (IPBinds _ ip_binds)) thing_inside
where
ips = [ip | (dL->L _ (IPBind _ (Left (dL->L _ ip)) _)) <- ip_binds]
-- I wonder if we should do these one at at time
-- I wonder if we should do these one at a time
-- Consider ?x = 4
-- ?y = ?x + 1
tc_ip_bind ipClass (IPBind _ (Left (dL->L _ ip)) expr)
......
......@@ -78,7 +78,7 @@ would implicitly declare
(forall b. Ord b => a -> b -> b)
(We could use a record decl, but that means changing more of the existing apparatus.
One step at at time!)
One step at a time!)
For classes with just one superclass+method, we use a newtype decl instead:
......
......@@ -369,7 +369,7 @@ the rest of the instance. The fact that it is suspended is important, because
right now, we don't have ThetaTypes for the instances that use deriving clauses
(only the standalone-derived ones).
Now we can can collect the type family instances and extend the local instance
Now we can collect the type family instances and extend the local instance
environment. At this point, it is safe to run simplifyInstanceContexts on the
deriving-clause instance specs, which gives us the ThetaTypes for the
deriving-clause instances. Now we can feed all the ThetaTypes to the
......
......@@ -509,7 +509,7 @@ isTypeClosedLetBndr = noFreeVarsOfType . idType
tcExtendRecIds :: [(Name, TcId)] -> TcM a -> TcM a
-- Used for binding the recurive uses of Ids in a binding
-- both top-level value bindings and and nested let/where-bindings
-- both top-level value bindings and nested let/where-bindings
-- Does not extend the TcBinderStack
tcExtendRecIds pairs thing_inside
= tc_extend_local_env NotTopLevel
......@@ -533,7 +533,7 @@ tcExtendSigIds top_lvl sig_ids thing_inside
tcExtendLetEnv :: TopLevelFlag -> TcSigFun -> IsGroupClosed
-> [TcId] -> TcM a -> TcM a
-- Used for both top-level value bindings and and nested let/where-bindings
-- Used for both top-level value bindings and nested let/where-bindings
-- Adds to the TcBinderStack too
tcExtendLetEnv top_lvl sig_fn (IsGroupClosed fvs fv_type_closed)
ids thing_inside
......
......@@ -714,7 +714,7 @@ other examples where lazy flattening caused problems.
Bottom line: FM_Avoid is unused for now (Nov 14).
Note: T5321Fun got faster when I disabled FM_Avoid
T5837 did too, but it's pathalogical anyway
T5837 did too, but it's pathological anyway
Note [Phantoms in the flattener]
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
......@@ -1708,7 +1708,7 @@ is an example; all the constraints here are Givens
inert fsk ~ ((fsk3, TF Int), TF Int)
Because the incoming given rewrites all the inert givens, we get more and
more duplication in the inert set. But this really only happens in pathalogical
more duplication in the inert set. But this really only happens in pathological
casee, so we don't care.
......
......@@ -1101,7 +1101,7 @@ So for now I'm just insisting on type *equality* in patterns. No subsumption.
Old notes about desugaring, at a time when pattern coercions were handled:
A SigPat is a type coercion and must be handled one at at time. We can't
A SigPat is a type coercion and must be handled one at a time. We can't
combine them unless the type of the pattern inside is identical, and we don't
bother to check for that. For example:
......
......@@ -1715,7 +1715,7 @@ uUnfilledVar2 origin t_or_k swapped tv1 ty2
= do { traceTc "uUnfilledVar2 not ok" (ppr tv1 $$ ppr ty2)
-- Occurs check or an untouchable: just defer
-- NB: occurs check isn't necessarily fatal:
-- eg tv1 occured in type family parameter
-- eg tv1 occurred in type family parameter
; defer }
ty1 = mkTyVarTy tv1
......
......@@ -922,7 +922,7 @@ we invoke
Although we have unified k and j, it's very important that we put
(Refl j), /not/ (Refl k) as the fourth argument to unify_tys.
If we put (Refl k) we'd end up with teh substitution
If we put (Refl k) we'd end up with the substitution
a :-> b |> Refl k
which is bogus because one of the template variables, k,
appears in the range of the substitution. Eek.
......
......@@ -449,7 +449,7 @@ putSLEB128 bh initial = go initial
let !val' = val `unsafeShiftR` 7
let !signBit = testBit byte 6
let !done =
-- Unsigned value, val' == 0 and and last value can
-- Unsigned value, val' == 0 and last value can
-- be discriminated from a negative number.
((val' == 0 && not signBit) ||
-- Signed value,
......
......@@ -4,22 +4,22 @@
% you write "\makeatactive". From then on, inline code is written as @\x
% -> x_1 & y@. The only difference with what you are used to, is that
% instead of
%
%
% @
% foo :: Int -> Int
% foo = \n -> n+1
% @
%
%
% you have to write
%
%
% \begin{code}
% foo :: Int -> Int
% foo = \n -> n+1
% \end{code}
%
% and that you cannot use @ in \section{} and \caption{}. For the paper that occured twice, in which case I had to replace @...@ b y \texttt{...}.
%
%
%
% and that you cannot use @ in \section{} and \caption{}. For the paper that occurred twice, in which case I had to replace @...@ b y \texttt{...}.
%
%
% code.sty --- nice verbatim mode for code
% To get '@' use \verb+@+
......
......@@ -4,22 +4,22 @@
% you write "\makeatactive". From then on, inline code is written as @\x
% -> x_1 & y@. The only difference with what you are used to, is that
% instead of
%
%
% @
% foo :: Int -> Int
% foo = \n -> n+1
% @
%
%
% you have to write
%
%
% \begin{code}
% foo :: Int -> Int
% foo = \n -> n+1
% \end{code}
%
% and that you cannot use @ in \section{} and \caption{}. For the paper that occured twice, in which case I had to replace @...@ b y \texttt{...}.
%
%
%
% and that you cannot use @ in \section{} and \caption{}. For the paper that occurred twice, in which case I had to replace @...@ b y \texttt{...}.
%
%
% code.sty --- nice verbatim mode for code
\def\icode{%
......
......@@ -2121,7 +2121,7 @@ On systems with ``.dll``-style shared libraries, the actual library
loaded will be ``lib.dll``, ``liblib.dll``. GHCi also has full support for
import libraries, either Microsoft style ``.lib``, or GNU GCC style ``.a`` and
``.dll.a`` libraries. If you have an import library it is advisable to always
specify the import libary instead of the ``.dll``. e.g. use ``-lgcc` instead of
specify the import library instead of the ``.dll``. e.g. use ``-lgcc` instead of
``-llibgcc_s_seh-1``. Again, GHCi will signal an error if it can't find the
library.
......
......@@ -597,7 +597,7 @@ The GHC API exposes functions for reading and writing these files.
Runs a series of sanity checks and lints on the extended interface files
that are being written out. These include testing things properties such as
variables not occuring outside of their expected scopes.
variables not occurring outside of their expected scopes.
The format in which GHC currently stores its typechecked AST, makes it costly
to collect the types for some expressions nodes. For the sake of performance,
......
......@@ -1605,7 +1605,7 @@ editFile str =
-- XXX: Can we figure out what happened if the depndecy analysis fails
-- (e.g., because the porgrammeer mistyped the name of a module)?
-- XXX: Can we figure out the location of an error to pass to the editor?
-- XXX: if we could figure out the list of errors that occured during the
-- XXX: if we could figure out the list of errors that occurred during the
-- last load/reaload, then we could start the editor focused on the first
-- of those.
chooseEditFile :: GHC.GhcMonad m => m String
......
......@@ -148,7 +148,7 @@ fromJust :: HasCallStack => Maybe a -> a
fromJust Nothing = error "Maybe.fromJust: Nothing" -- yuck
fromJust (Just x) = x
-- | The 'fromMaybe' function takes a default value and and 'Maybe'
-- | The 'fromMaybe' function takes a default value and a 'Maybe'
-- value. If the 'Maybe' is 'Nothing', it returns the default values;
-- otherwise, it returns the value contained in the 'Maybe'.
--
......
......@@ -87,7 +87,7 @@ last [] = errorEmptyList "last"
#else
-- Use foldl to make last a good consumer.
-- This will compile to good code for the actual GHC.List.last.
-- (At least as long it is eta-expaned, otherwise it does not, #10260.)
-- (At least as long it is eta-expanded, otherwise it does not, #10260.)
last xs = foldl (\_ x -> x) lastError xs
{-# INLINE last #-}
-- The inline pragma is required to make GHC remember the implementation via
......
......@@ -51,7 +51,7 @@ default ()
--
-- {-# CONSTANT_FOLDED plusInteger #-}
--
-- which is simply expaned into a
-- which is simply expanded into a
--
-- {-# NOINLINE plusInteger #-}
--
......
......@@ -374,7 +374,7 @@ computeRetainerSet( traverseState *ts )
// all are guaranteed to be valid, or reachable.
//
// The following code assumes that WEAK objects are considered to be roots
// for retainer profilng.
// for retainer profiling.
for (n = 0; n < n_capabilities; n++) {
// NB: after a GC, all nursery weak_ptr_lists have been migrated
// to the global lists living in the generations
......
......@@ -32,7 +32,7 @@
for garbage collection because the act of passing them makes a copy
from the heap, stack or wherever they are onto the C-world stack.
However, if we were to pass a heap object such as a (Haskell) @String@
and a garbage collection occured before we finished using it, we'd run
and a garbage collection occurred before we finished using it, we'd run
into problems since the heap object might have been moved or even
deleted.
......
......@@ -7,7 +7,7 @@ import Control.Arrow
cc1 :: a e b -> a e b -> a e b
cc1 = undefined
-- With GHC < 7.10.1, the following compile failures occured:
-- With GHC < 7.10.1, the following compile failures occurred:
--
-- ghc: panic! (the 'impossible' happened)
-- (GHC version 7.8.4 for x86_64-unknown-linux):
......
{-# LANGUAGE TypeFamilies, PartialTypeSignatures #-}
-- In #12033 this was called HsakellBug.hs
-- In #12033 this was called HaskellBug.hs
module T12033 where
tripleStoreToRuleSet :: v -> v
......
......@@ -7,7 +7,7 @@ module CyclicSubst where
-- | The match is translated to @b | a <- b@, the initial unification variable
-- is @a@ (for some reason). VarVar will assign @b :-> a@ in the match of @a@
-- against @b@ (vars occurring in a pattern are flexible). The @PmGrd a b@ is
-- desugared as a match of @$pm_x@ against @a@, where @$pm_x :-> b@, which is
-- stored as @$pm_x :-> a@ due to the previous solution. Now, VarVar will
-- assign @a :-> $pm_x@, causing a cycle.
......
......@@ -427,7 +427,7 @@ wrapOp :: String -> String
wrapOp nm | isAlpha (head nm) = nm
| otherwise = "(" ++ nm ++ ")"
-- | Turn an identifer or operator into its infix form
-- | Turn an identifier or operator into its infix form
asInfix :: String -> String
asInfix nm | isAlpha (head nm) = "`" ++ nm ++ "`"
| otherwise = nm
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment