Commit 3e1745aa authored by Gabor Greif's avatar Gabor Greif 💬

typos

parent a217e7a2
......@@ -291,7 +291,7 @@ mkDictSelId dflags no_unf name clas
else mkImplicitUnfolding dflags rhs)
-- In module where class op is defined, we must add
-- the unfolding, even though it'll never be inlined
-- becuase we use that to generate a top-level binding
-- because we use that to generate a top-level binding
-- for the ClassOp
info | new_tycon = base_info `setInlinePragInfo` alwaysInlinePragma
......
......@@ -257,7 +257,7 @@ data RealSrcSpan
srcSpanLine :: {-# UNPACK #-} !Int,
srcSpanCol :: {-# UNPACK #-} !Int
}
deriving (Eq, Typeable, Show) -- Show is used by Lexer.x, becuase we
deriving (Eq, Typeable, Show) -- Show is used by Lexer.x, because we
-- derive Show for Token
data SrcSpan =
......@@ -265,7 +265,7 @@ data SrcSpan =
| UnhelpfulSpan !FastString -- Just a general indication
-- also used to indicate an empty span
deriving (Eq, Typeable, Show) -- Show is used by Lexer.x, becuase we
deriving (Eq, Typeable, Show) -- Show is used by Lexer.x, because we
-- derive Show for Token
-- | Built-in "bad" 'SrcSpan's for common sources of location uncertainty
......
......@@ -352,7 +352,7 @@ idDetails (Id { id_details = details }) = details
idDetails other = pprPanic "idDetails" (ppr other)
-- The next three have a 'Var' suffix even though they always build
-- Ids, becuase Id.lhs uses 'mkGlobalId' etc with different types
-- Ids, because Id.lhs uses 'mkGlobalId' etc with different types
mkGlobalVar :: IdDetails -> Name -> Type -> IdInfo -> Id
mkGlobalVar details name ty info
= mk_id name ty GlobalId details info
......
......@@ -202,7 +202,7 @@ slightly more complicated, does) turn into
blah = op (\eta. ($dfList dCInt |> sym co) eta)
and now it is *much* harder for the op/$dfList rule to fire, becuase
and now it is *much* harder for the op/$dfList rule to fire, because
exprIsConApp_maybe won't hold of the argument to op. I considered
trying to *make* it hold, but it's tricky and I gave up.
......
......@@ -144,7 +144,7 @@ lintCoreBindings binds
-- allow this at top level:
-- M.n{r3} = ...
-- M.n{r29} = ...
-- becuase they both get the same linker symbol
-- because they both get the same linker symbol
ext_dups = snd (removeDups ord_ext (map Var.varName binders))
ord_ext n1 n2 | Just m1 <- nameModule_maybe n1
, Just m2 <- nameModule_maybe n2
......
......@@ -436,7 +436,7 @@ substBind subst (Rec pairs) = (subst', Rec (bndrs' `zip` rhss'))
\begin{code}
-- | De-shadowing the program is sometimes a useful pre-pass. It can be done simply
-- by running over the bindings with an empty substitution, becuase substitution
-- by running over the bindings with an empty substitution, because substitution
-- returns a result that has no-shadowing guaranteed.
--
-- (Actually, within a single /type/ there might still be shadowing, because
......@@ -868,7 +868,7 @@ simpleOptExpr :: CoreExpr -> CoreExpr
-- We also inline bindings that bind a Eq# box: see
-- See Note [Optimise coercion boxes agressively].
--
-- The result is NOT guaranteed occurence-analysed, becuase
-- The result is NOT guaranteed occurence-analysed, because
-- in (let x = y in ....) we substitute for x; so y's occ-info
-- may change radically
......
......@@ -525,7 +525,7 @@ There used to be a gruesome test for (hasNoBinding v) in the
Var case:
exprIsTrivial (Var v) | hasNoBinding v = idArity v == 0
The idea here is that a constructor worker, like \$wJust, is
really short for (\x -> \$wJust x), becuase \$wJust has no binding.
really short for (\x -> \$wJust x), because \$wJust has no binding.
So it should be treated like a lambda. Ditto unsaturated primops.
But now constructor workers are not "have-no-binding" Ids. And
completely un-applied primops and foreign-call Ids are sufficiently
......
......@@ -371,7 +371,7 @@ dsRule (L loc (HsRule name act vars lhs _tv_lhs rhs _fv_rhs))
Right (final_bndrs, fn_id, args) -> do
{ let is_local = isLocalId fn_id
-- NB: isLocalId is False of implicit Ids. This is good becuase
-- NB: isLocalId is False of implicit Ids. This is good because
-- we don't want to attach rules to the bindings of implicit Ids,
-- because they don't show up in the bindings until just before code gen
fn_name = idName fn_id
......
......@@ -662,8 +662,8 @@ It's true that this *is* a more specialised type, but the rule
we get is something like this:
f_spec d = f
RULE: f = f_spec d
Note that the rule is bogus, becuase it mentions a 'd' that is
not bound on the LHS! But it's a silly specialisation anyway, becuase
Note that the rule is bogus, because it mentions a 'd' that is
not bound on the LHS! But it's a silly specialisation anyway, because
the constraint is unused. We could bind 'd' to (error "unused")
but it seems better to reject the program because it's almost certainly
a mistake. That's what the isDeadBinder call detects.
......
......@@ -820,7 +820,7 @@ conversionNames
= [ toIntegerName, toRationalName
, fromIntegralName, realToFracName ]
-- We can't easily add fromIntegerName, fromRationalName,
-- becuase they are generated by literals
-- because they are generated by literals
\end{code}
%************************************************************************
......
......@@ -8,7 +8,7 @@
-- CoreExpr's of the "smart constructors" of the Meta.Exp datatype.
--
-- It also defines a bunch of knownKeyNames, in the same way as is done
-- in prelude/PrelNames. It's much more convenient to do it here, becuase
-- in prelude/PrelNames. It's much more convenient to do it here, because
-- otherwise we have to recompile PrelNames whenever we add a Name, which is
-- a Royal Pain (triggers other recompilation).
-----------------------------------------------------------------------------
......@@ -351,7 +351,7 @@ repClsInstD (ClsInstDecl { cid_poly_ty = ty, cid_binds = binds
-- appear in the resulting data structure
--
-- But we do NOT bring the binders of 'binds' into scope
-- becuase they are properly regarded as occurrences
-- because they are properly regarded as occurrences
-- For example, the method names should be bound to
-- the selector Ids, not to fresh names (Trac #5410)
--
......@@ -1876,7 +1876,7 @@ mk_string s = return $ HsString s
repOverloadedLiteral :: HsOverLit Name -> DsM (Core TH.Lit)
repOverloadedLiteral (OverLit { ol_val = val})
= do { lit <- mk_lit val; repLiteral lit }
-- The type Rational will be in the environment, becuase
-- The type Rational will be in the environment, because
-- the smart constructor 'TH.Syntax.rationalL' uses it in its type,
-- and rationalL is sucked in when any TH stuff is used
......
......@@ -291,7 +291,7 @@ mkCoAlgCaseMatchResult dflags var ty match_alts
= MatchResult fail_flag mk_case
where
tycon = dataConTyCon con1
-- [Interesting: becuase of GADTs, we can't rely on the type of
-- [Interesting: because of GADTs, we can't rely on the type of
-- the scrutinised Id to be sufficiently refined to have a TyCon in it]
-- Stuff for newtype
......
......@@ -113,7 +113,7 @@ dsOverLit' dflags (OverLit { ol_val = val, ol_rebindable = rebindable
Note [Literal short cut]
~~~~~~~~~~~~~~~~~~~~~~~~
The type checker tries to do this short-cutting as early as possible, but
becuase of unification etc, more information is available to the desugarer.
because of unification etc, more information is available to the desugarer.
And where it's possible to generate the correct literal right away, it's
much better do do so.
......
......@@ -206,7 +206,7 @@ type IfaceAnnTarget = AnnTarget OccName
-- We only serialise the IdDetails of top-level Ids, and even then
-- we only need a very limited selection. Notably, none of the
-- implicit ones are needed here, becuase they are not put it
-- implicit ones are needed here, because they are not put it
-- interface files
data IfaceIdDetails
......
......@@ -476,7 +476,7 @@ Note [Don't attempt to trim data types]
For some time GHC tried to avoid exporting the data constructors
of a data type if it wasn't strictly necessary to do so; see Trac #835.
But "strictly necessary" accumulated a longer and longer list
of execeptions, and finally I gave up the battle:
of exceptions, and finally I gave up the battle:
commit 9a20e540754fc2af74c2e7392f2786a81d8d5f11
Author: Simon Peyton Jones <simonpj@microsoft.com>
......@@ -525,7 +525,7 @@ Id still makes sense.]
At one time I tried injecting the implicit bindings *early*, at the
beginning of SimplCore. But that gave rise to real difficulty,
becuase GlobalIds are supposed to have *fixed* IdInfo, but the
because GlobalIds are supposed to have *fixed* IdInfo, but the
simplifier and other core-to-core passes mess with IdInfo all the
time. The straw that broke the camels back was when a class selector
got the wrong arity -- ie the simplifier gave it arity 2, whereas
......
......@@ -749,7 +749,7 @@ getRegister' _ is32Bit (CmmMachOp mop [x, y]) = do -- dyadic MachOps
* so we can either:
- do y first, put its result in a fresh tmp, then copy it to %ecx later
- do y second and put its result into %ecx. x gets placed in a fresh
tmp. This is likely to be better, becuase the reg alloc can
tmp. This is likely to be better, because the reg alloc can
eliminate this reg->reg move here (it won't eliminate the other one,
because the move is into the fixed %ecx).
-}
......
......@@ -241,7 +241,7 @@ funTyCon = mkFunTyCon funTyConName $
-- You might think that (->) should have type (?? -> ? -> *), and you'd be right
-- But if we do that we get kind errors when saying
-- instance Control.Arrow (->)
-- becuase the expected kind is (*->*->*). The trouble is that the
-- because the expected kind is (*->*->*). The trouble is that the
-- expected/actual stuff in the unifier does not go contra-variant, whereas
-- the kind sub-typing does. Sigh. It really only matters if you use (->) in
-- a prefix way, thus: (->) Int# Int#. And this is unusual.
......@@ -653,7 +653,7 @@ The type constructor Any of kind forall k. k -> k has these properties:
* It is a *closed* type family, with no instances. This means that
if ty :: '(k1, k2) we add a given coercion
g :: ty ~ (Fst ty, Snd ty)
If Any was a *data* type, then we'd get inconsistency becuase 'ty'
If Any was a *data* type, then we'd get inconsistency because 'ty'
could be (Any '(k1,k2)) and then we'd have an equality with Any on
one side and '(,) on the other
......
......@@ -440,7 +440,7 @@ Thus:
instance C S where
data G S = Y1 | Y2
Even though there are two G's in scope (M.G and Blib.G), the occurence
of 'G' in the 'instance C S' decl is unambiguous, becuase C has only
of 'G' in the 'instance C S' decl is unambiguous, because C has only
one associated type called G. This is exactly what happens for methods,
and it is only consistent to do the same thing for types. That's the
role of the function lookupTcdName; the (Maybe Name) give the class of
......
......@@ -1056,7 +1056,7 @@ rn_rec_stmt _ all_bndrs (L loc (LetStmt (HsValBinds binds'))) _ = do
return [(duDefs du_binds, allUses du_binds,
emptyNameSet, L loc (LetStmt (HsValBinds binds')))]
-- no RecStmt case becuase they get flattened above when doing the LHSes
-- no RecStmt case because they get flattened above when doing the LHSes
rn_rec_stmt _ _ stmt@(L _ (RecStmt {})) _
= pprPanic "rn_rec_stmt: RecStmt" (ppr stmt)
......
......@@ -905,7 +905,7 @@ What does M export? AvailTC F [FInt]
The former is strictly right because F isn't defined in this module.
But then you can never do an explicit import of M, thus
import M( F( FInt ) )
becuase F isn't exported by M. Nor can you import FInt alone from here
because F isn't exported by M. Nor can you import FInt alone from here
import M( FInt )
because we don't have syntax to support that. (It looks like an import of
the type FInt.)
......@@ -1334,7 +1334,7 @@ each import declaration, what stuff brought into scope by that
declaration is actually used in the module.
The SrcLoc is the location of the END of a particular 'import'
declaration. Why *END*? Becuase we don't want to get confused
declaration. Why *END*? Because we don't want to get confused
by the implicit Prelude import. Consider (Trac #7476) the module
import Foo( foo )
main = print foo
......
......@@ -277,7 +277,7 @@ We get the following levels
Then 'x' is being scrutinised at a deeper level than its binding, so
it's added to lc_sruts: [(x,1)]
We do *not* want to specialise the call to 'f', becuase 'x' is not free
We do *not* want to specialise the call to 'f', because 'x' is not free
in 'f'. So here the bind-level of 'x' (=1) is not <= the bind-level of 'f' (=0).
We *do* want to specialise the call to 'g', because 'x' is free in g.
......
......@@ -855,7 +855,7 @@ makeIndEnv binds
shortMeOut :: IndEnv -> Id -> Id -> Bool
shortMeOut ind_env exported_id local_id
-- The if-then-else stuff is just so I can get a pprTrace to see
-- how often I don't get shorting out becuase of IdInfo stuff
-- how often I don't get shorting out because of IdInfo stuff
= if isExportedId exported_id && -- Only if this is exported
isLocalId local_id && -- Only if this one is defined in this
......
......@@ -679,7 +679,7 @@ We *do* transfer the arity from from the in_id of a let binding to the
out_id. This is important, so that the arity of an Id is visible in
its own RHS. For example:
f = \x. ....g (\y. f y)....
We can eta-reduce the arg to g, becuase f is a value. But that
We can eta-reduce the arg to g, because f is a value. But that
needs to be visible.
This interacts with the 'state hack' too:
......
......@@ -509,7 +509,7 @@ updModeForInlineRules inline_rule_act current_mode
, sm_inline = True
, sm_eta_expand = False }
-- For sm_rules, just inherit; sm_rules might be "off"
-- becuase of -fno-enable-rewrite-rules
-- because of -fno-enable-rewrite-rules
where
phaseFromActivation (ActiveAfter n) = Phase n
phaseFromActivation _ = InitialPhase
......@@ -933,7 +933,7 @@ postInlineUnconditionally dflags env top_lvl bndr occ_info rhs unfolding
= case occ_info of
-- The point of examining occ_info here is that for *non-values*
-- that occur outside a lambda, the call-site inliner won't have
-- a chance (becuase it doesn't know that the thing
-- a chance (because it doesn't know that the thing
-- only occurs once). The pre-inliner won't have gotten
-- it either, if the thing occurs in more than one branch
-- So the main target is things like
......
......@@ -331,7 +331,7 @@ simplLazyBind env top_lvl is_rec bndr bndr1 rhs rhs_se
not_lam (Lam _ _) = False
not_lam _ = True
-- Do not do the "abstract tyyvar" thing if there's
-- a lambda inside, becuase it defeats eta-reduction
-- a lambda inside, because it defeats eta-reduction
-- f = /\a. \x. g a x
-- should eta-reduce
......@@ -781,7 +781,7 @@ on to the old unfolding (which is part of the id).
Note [Arity decrease]
~~~~~~~~~~~~~~~~~~~~~
Generally speaking the arity of a binding should not decrease. But it *can*
legitimately happen becuase of RULES. Eg
legitimately happen because of RULES. Eg
f = g Int
where g has arity 2, will have arity 2. But if there's a rewrite rule
g Int --> h
......@@ -2347,7 +2347,7 @@ mkDupableCont env (Select _ case_bndr alts se cont)
; (env', dup_cont, nodup_cont) <- prepareCaseCont env alts cont
-- NB: We call prepareCaseCont here. If there is only one
-- alternative, then dup_cont may be big, but that's ok
-- becuase we push it into the single alternative, and then
-- because we push it into the single alternative, and then
-- use mkDupableAlt to turn that simplified alternative into
-- a join point if it's too big to duplicate.
-- And this is important: see Note [Fusing case continuations]
......
......@@ -587,7 +587,7 @@ We get two specialisations:
But perhaps the first one isn't good. After all, we know that tpl_B2 is
a T (I# x) really, because T is strict and Int has one constructor. (We can't
unbox the strict fields, becuase T is polymorphic!)
unbox the strict fields, because T is polymorphic!)
%************************************************************************
%* *
......@@ -867,7 +867,7 @@ specialiations. Consider
If we specialise $j1 then in each specialisation (as well as the original)
we can specialise $j2, and similarly $j3. Even if we make just *one*
specialisation of each, becuase we also have the original we'll get 2^n
specialisation of each, because we also have the original we'll get 2^n
copies of $j3, which is not good.
So when recursively specialising we divide the sc_count by the number of
......
......@@ -626,7 +626,7 @@ specImport :: DynFlags
specImport dflags done rb fn calls_for_fn
| fn `elemVarSet` done
= return ([], []) -- No warning. This actually happens all the time
-- when specialising a recursive function, becuase
-- when specialising a recursive function, because
-- the RHS of the specialised function contains a recursive
-- call to the original function
......
......@@ -232,7 +232,7 @@ lintStgAlts alts scrut_ty = do
where
-- check ty = checkTys first_ty ty (mkCaseAltMsg alts)
-- We can't check that the alternatives have the
-- same type, becuase they don't, with unsafeCoerce#
-- same type, because they don't, with unsafeCoerce#
lintAlt :: Type -> (AltCon, [Id], [Bool], StgExpr) -> LintM (Maybe Type)
lintAlt _ (DEFAULT, _, _, rhs)
......
......@@ -686,7 +686,7 @@ mkTyVarEqErr dflags ctxt extra ct oriented tv1 ty2
= reportEqErr ctxt extra ct oriented (mkTyVarTy tv1) ty2
-- This *can* happen (Trac #6123, and test T2627b)
-- Consider an ambiguous top-level constraint (a ~ F a)
-- Not an occurs check, becuase F is a type function.
-- Not an occurs check, because F is a type function.
where
occ_check_expand = occurCheckExpand dflags tv1 ty2
k1 = tyVarKind tv1
......@@ -866,7 +866,7 @@ mkDictErr ctxt cts
-- Report definite no-instance errors,
-- or (iff there are none) overlap errors
-- But we report only one of them (hence 'head') becuase they all
-- But we report only one of them (hence 'head') because they all
-- have the same source-location origin, to try avoid a cascade
-- of error from one location
; (ctxt, err) <- mk_dict_err ctxt (head (no_inst_cts ++ overlap_cts))
......
......@@ -536,7 +536,7 @@ handle the *non-updated* fields. Consider:
The result type should be (T a b' c)
not (T a b c), because 'b' *is not* mentioned in a non-updated field
not (T a b' c'), becuase 'c' *is* mentioned in a non-updated field
not (T a b' c'), because 'c' *is* mentioned in a non-updated field
NB that it's not good enough to look at just one constructor; we must
look at them all; cf Trac #3219
......
......@@ -500,7 +500,7 @@ unliftedCompare :: PrimOp -> PrimOp
-- Return (if a < b then lt else if a == b then eq else gt)
unliftedCompare lt_op eq_op a_expr b_expr lt eq gt
= nlHsIf (genOpApp a_expr (primOpRdrName lt_op) b_expr) lt $
-- Test (<) first, not (==), becuase the latter
-- Test (<) first, not (==), because the latter
-- is true less often, so putting it first would
-- mean more tests (dynamically)
nlHsIf (genOpApp a_expr (primOpRdrName eq_op) b_expr) eq gt
......@@ -690,7 +690,7 @@ instance ... Ix (Foo ...) where
map tag2con_Foo (enumFromTo (I# a#) (I# b#))
}}
-- Generate code for unsafeIndex, becuase using index leads
-- Generate code for unsafeIndex, because using index leads
-- to lots of redundant range tests
unsafeIndex c@(a, b) d
= case (con2tag_Foo d -# con2tag_Foo a) of
......
......@@ -123,7 +123,7 @@ hsLitType (HsFloatPrim _) = floatPrimTy
hsLitType (HsDoublePrim _) = doublePrimTy
\end{code}
Overloaded literals. Here mainly becuase it uses isIntTy etc
Overloaded literals. Here mainly because it uses isIntTy etc
\begin{code}
shortCutLit :: DynFlags -> OverLitVal -> TcType -> Maybe (HsExpr TcId)
......
......@@ -961,7 +961,7 @@ and *not* at the inner forall:
f2 :: (forall k. forall (a:k). T k a -> Int) -> Int -- NO!
Reason: same as for HM inference on value level declarations,
we want to infer the most general type. The f2 type signature
would be *less applicable* than f1, becuase it requires a more
would be *less applicable* than f1, because it requires a more
polymorphic argument.
Note [Kinds of quantified type variables]
......
......@@ -737,7 +737,7 @@ Note that
c) There are several type instance decls for T in the instance
All this is fine. Of course, you can't give any *more* instances
for (T ty Int) elsewhere, becuase it's an *associated* type.
for (T ty Int) elsewhere, because it's an *associated* type.
Note [Checking consistent instantiation]
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
......@@ -824,7 +824,7 @@ checkConsistentFamInst (Just (clas, mini_env)) flav fam_tc at_tvs at_tys
= case tcMatchTyX at_tv_set subst at_ty inst_ty of
Just subst | all_distinct subst -> return subst
_ -> failWithTc $ wrongATArgErr at_ty inst_ty
-- No need to instantiate here, becuase the axiom
-- No need to instantiate here, because the axiom
-- uses the same type variables as the assocated class
| otherwise
= return subst -- Allow non-type-variable instantiation
......@@ -1014,7 +1014,7 @@ mkMethIds sig_fn clas tyvars dfun_ev_vars inst_tys sel_id
= do { let sel_occ = nameOccName sel_name
; meth_name <- newName (mkClassOpAuxOcc sel_occ)
; local_meth_name <- newName sel_occ
-- Base the local_meth_name on the selector name, becuase
-- Base the local_meth_name on the selector name, because
-- type errors from tcInstanceMethodBody come from here
; local_meth_sig <- case lookupHsSig sig_fn sel_name of
......
......@@ -1200,7 +1200,7 @@ then overwrite the Eq t constraint with a superclass selection!
At first I had a gross hack, whereby I simply did not add superclass constraints
in addWanted, though I did for addGiven and addIrred. This was sub-optimal,
becuase it lost legitimate superclass sharing, and it still didn't do the job:
because it lost legitimate superclass sharing, and it still didn't do the job:
I found a very obscure program (now tcrun021) in which improvement meant the
simplifier got two bites a the cherry... so something seemed to be an Stop
first time, but reducible next time.
......
......@@ -891,7 +891,7 @@ Here the 'proc (y,z)' binding scopes over the arrow tails but not the
arrow body (e.g 'term'). As things stand (bogusly) all the
constraints from the proc body are gathered together, so constraints
from 'term' will be seen by the tcPat for (y,z). But we must *not*
bind constraints from 'term' here, becuase the desugarer will not make
bind constraints from 'term' here, because the desugarer will not make
these bindings scope over 'term'.
The Right Thing is not to confuse these constraints together. But for
......@@ -923,7 +923,7 @@ generate the translated term
f = \x' :: (forall a. a->a). let x = x' Int in x 3
From a type-system point of view, this is perfectly fine, but it's *very* seldom useful.
And it requires a significant amount of code to implement, becuase we need to decorate
And it requires a significant amount of code to implement, because we need to decorate
the translated pattern with coercion functions (generated from the subsumption check
by tcSub).
......
......@@ -1289,7 +1289,7 @@ The Ids bound by previous Stmts in GHCi are currently
generator will consider the occurrences to be free rather than
global.
(b) They retain their Internal names becuase we don't have a suitable
(b) They retain their Internal names because we don't have a suitable
Module to name them with. We could revisit this choice.
(c) Their types are tidied. This is important, because :info may ask
......
......@@ -262,7 +262,7 @@ data TcGblEnv
-- ^ @True@ <=> Template Haskell syntax used.
--
-- We need this so that we can generate a dependency on the
-- Template Haskell package, becuase the desugarer is going
-- Template Haskell package, because the desugarer is going
-- to emit loads of references to TH symbols. The reference
-- is implicit rather than explicit, so we have to zap a
-- mutable variable.
......
......@@ -368,7 +368,7 @@ There are two types we might infer for f:
f :: (?y::Int) => Int -> Int
At first you might think the first was better, becuase then
At first you might think the first was better, because then
?y behaves like a free variable of the definition, rather than
having to be passed at each call site. But of course, the WHOLE
IDEA is that ?y should be passed at each call site (that's what
......
......@@ -105,7 +105,7 @@ very straightforwardly:
e.g for HsType, rename and kind-check
for HsExpr, rename and type-check
(The last step is different for decls, becuase they can *only* be
(The last step is different for decls, because they can *only* be
top-level: we return the result of step 2.)
Note [How brackets and nested splices are handled]
......@@ -669,7 +669,7 @@ defined in another module, because we are going to run it here. It's
a bit like a TH splice:
$(p "stuff")
However, you can do this in patterns as well as terms. Becuase of this,
However, you can do this in patterns as well as terms. Because of this,
the splice is run by the *renamer* rather than the type checker.
%************************************************************************
......
......@@ -1236,7 +1236,7 @@ checkValidFamDecl (FamilyDecl { fdLName = lname, fdFlavour = flav })
-- module alpha conversion of the quantified type variables
-- of the constructor.
--
-- Note that we allow existentials to match becuase the
-- Note that we allow existentials to match because the
-- fields can never meet. E.g
-- data T where
-- T1 { f1 :: b, f2 :: a, f3 ::Int } :: T
......@@ -1530,7 +1530,7 @@ Consider this (Trac #4169):
When we typecheck 'ast' we have done the first pass over the class decl
(in tcTyClDecls), but we have not yet typechecked the default-method
declarations (becuase they can mention value declarations). So we
declarations (because they can mention value declarations). So we
must bring the default method Ids into scope first (so they can be seen
when typechecking the [d| .. |] quote, and typecheck them later.
......
......@@ -109,7 +109,7 @@ namely:
This is not (currently) where deep skolemisation occurs;
matchExpectedFunTys does not skolmise nested foralls in the
expected type, becuase it expects that to have been done already
expected type, because it expects that to have been done already
\begin{code}
......
......@@ -497,13 +497,13 @@ etaTyConAppCo_maybe tc co
Note [Eta for AppCo]
~~~~~~~~~~~~~~~~~~~~
Supopse we have
Suppose we have
g :: s1 t1 ~ s2 t2
Then we can't necessarily make
left g :: s1 ~ s2
right g :: t1 ~ t2
becuase it's poossible that
because it's possible that
s1 :: * -> * t1 :: *
s2 :: (*->*) -> * t2 :: * -> *
and in that case (left g) does not have the same
......
......@@ -1167,7 +1167,7 @@ isTupleTyCon :: TyCon -> Bool
-- ^ Does this 'TyCon' represent a tuple?
--
-- NB: when compiling @Data.Tuple@, the tycons won't reply @True@ to
-- 'isTupleTyCon', becuase they are built as 'AlgTyCons'. However they
-- 'isTupleTyCon', because they are built as 'AlgTyCons'. However they
-- get spat into the interface file as tuple tycons, so I don't think
-- it matters.
isTupleTyCon (TupleTyCon {}) = True
......
......@@ -747,7 +747,7 @@ pprArrowChain p (arg:args) = maybeParen p FunPrec $
%* *
%************************************************************************
Tidying is here becuase it has a special case for FlatSkol
Tidying is here because it has a special case for FlatSkol
\begin{code}
-- | This tidies up a type for printing in an error message, or in
......
......@@ -793,7 +793,7 @@ live static closure to a correct null value before its destruction.
This is done by invoking the function
@resetStaticObjectForRetainerProfiling()@.
\textbf{To do:} In the current implemenation, if a static closure has no child
\textbf{To do:} In the current implementation, if a static closure has no child
(e.g., @CONSTR_NOCAF_STATIC@, @THUNK_STATIC@ with an empty SRT, and
@FUN_STATIC@ with an empty SRT), we do not compute its retainer set (because
there is no need to do). This slight optimization allows us to render
......
......@@ -19,7 +19,7 @@
-------------------------------------------------------------------------- */
typedef struct _StgEntCounter {
/* Using StgWord for everything, becuase both the C and asm code
/* Using StgWord for everything, because both the C and asm code
generators make trouble if you try to pack things tighter */
StgWord registeredp; /* 0 == no, 1 == yes */
StgInt arity; /* arity (static info) */
......
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