@@ -1493,7 +1493,7 @@ void Sema::ActOnExitFunctionContext() {
1493
1493
///
1494
1494
/// This routine determines whether overloading is possible, not
1495
1495
/// whether a new declaration actually overloads a previous one.
1496
- /// It will return true in C++ (where overloads are alway permitted)
1496
+ /// It will return true in C++ (where overloads are always permitted)
1497
1497
/// or, as a C extension, when either the new declaration or a
1498
1498
/// previous one is declared with the 'overloadable' attribute.
1499
1499
static bool AllowOverloadingOfFunction(const LookupResult &Previous,
@@ -4147,7 +4147,7 @@ bool Sema::MergeFunctionDecl(FunctionDecl *New, NamedDecl *&OldD, Scope *S,
4147
4147
4148
4148
// If we are merging two functions where only one of them has a prototype,
4149
4149
// we may have enough information to decide to issue a diagnostic that the
4150
- // function without a protoype will change behavior in C23. This handles
4150
+ // function without a prototype will change behavior in C23. This handles
4151
4151
// cases like:
4152
4152
// void i(); void i(int j);
4153
4153
// void i(int j); void i();
@@ -10553,7 +10553,7 @@ Sema::ActOnFunctionDeclarator(Scope *S, Declarator &D, DeclContext *DC,
10553
10553
if (getLangOpts().CUDA && !isFunctionTemplateSpecialization)
10554
10554
CUDA().maybeAddHostDeviceAttrs(NewFD, Previous);
10555
10555
10556
- // Handle explict specializations of function templates
10556
+ // Handle explicit specializations of function templates
10557
10557
// and friend function declarations with an explicit
10558
10558
// template argument list.
10559
10559
if (isFunctionTemplateSpecialization) {
@@ -12601,7 +12601,7 @@ void Sema::CheckMSVCRTEntryPoint(FunctionDecl *FD) {
12601
12601
if (FD->getName() != "DllMain")
12602
12602
FD->setHasImplicitReturnZero(true);
12603
12603
12604
- // Explicity specified calling conventions are applied to MSVC entry points
12604
+ // Explicitly specified calling conventions are applied to MSVC entry points
12605
12605
if (!hasExplicitCallingConv(T)) {
12606
12606
if (isDefaultStdCall(FD, *this)) {
12607
12607
if (FT->getCallConv() != CC_X86StdCall) {
@@ -13674,12 +13674,12 @@ void Sema::AddInitializerToDecl(Decl *RealDecl, Expr *Init, bool DirectInit) {
13674
13674
CreateRecoveryExpr(Init->getBeginLoc(), Init->getEndLoc(), Args);
13675
13675
if (RecoveryExpr.get())
13676
13676
VDecl->setInit(RecoveryExpr.get());
13677
- // In general, for error recovery purposes, the initalizer doesn't play
13677
+ // In general, for error recovery purposes, the initializer doesn't play
13678
13678
// part in the valid bit of the declaration. There are a few exceptions:
13679
13679
// 1) if the var decl has a deduced auto type, and the type cannot be
13680
13680
// deduced by an invalid initializer;
13681
- // 2) if the var decl is decompsition decl with a non-deduced type, and
13682
- // the initialization fails (e.g. `int [a] = {1, 2};`);
13681
+ // 2) if the var decl is a decomposition decl with a non-deduced type,
13682
+ // and the initialization fails (e.g. `int [a] = {1, 2};`);
13683
13683
// Case 1) was already handled elsewhere.
13684
13684
if (isa<DecompositionDecl>(VDecl)) // Case 2)
13685
13685
VDecl->setInvalidDecl();
@@ -13897,9 +13897,9 @@ void Sema::AddInitializerToDecl(Decl *RealDecl, Expr *Init, bool DirectInit) {
13897
13897
}
13898
13898
} else if (VDecl->isFileVarDecl()) {
13899
13899
// In C, extern is typically used to avoid tentative definitions when
13900
- // declaring variables in headers, but adding an intializer makes it a
13900
+ // declaring variables in headers, but adding an initializer makes it a
13901
13901
// definition. This is somewhat confusing, so GCC and Clang both warn on it.
13902
- // In C++, extern is often used to give implictly static const variables
13902
+ // In C++, extern is often used to give implicitly static const variables
13903
13903
// external linkage, so don't warn in that case. If selectany is present,
13904
13904
// this might be header code intended for C and C++ inclusion, so apply the
13905
13905
// C++ rules.
@@ -14093,7 +14093,7 @@ void Sema::ActOnUninitializedDecl(Decl *RealDecl) {
14093
14093
return;
14094
14094
}
14095
14095
}
14096
- // The declaration is unitialized , no need for further checks.
14096
+ // The declaration is uninitialized , no need for further checks.
14097
14097
return;
14098
14098
}
14099
14099
@@ -16324,7 +16324,7 @@ Decl *Sema::ActOnFinishFunctionBody(Decl *dcl, Stmt *Body,
16324
16324
FSI->ObjCWarnForNoDesignatedInitChain = false;
16325
16325
}
16326
16326
if (FSI->ObjCWarnForNoInitDelegation) {
16327
- // Don't issue this warning for unavaialable inits.
16327
+ // Don't issue this warning for unavailable inits.
16328
16328
if (!MD->isUnavailable())
16329
16329
Diag(MD->getLocation(),
16330
16330
diag::warn_objc_secondary_init_missing_init_call);
@@ -17876,7 +17876,7 @@ Sema::ActOnTag(Scope *S, unsigned TagSpec, TagUseKind TUK, SourceLocation KWLoc,
17876
17876
SkipBody->Previous = Def;
17877
17877
makeMergedDefinitionVisible(Hidden);
17878
17878
// Carry on and handle it like a normal definition. We'll
17879
- // skip starting the definitiion later.
17879
+ // skip starting the definition later.
17880
17880
}
17881
17881
} else if (!IsExplicitSpecializationAfterInstantiation) {
17882
17882
// A redeclaration in function prototype scope in C isn't
@@ -20475,7 +20475,7 @@ Sema::FunctionEmissionStatus Sema::getEmissionStatus(const FunctionDecl *FD,
20475
20475
} else if (LangOpts.OpenMP > 45) {
20476
20476
// In OpenMP host compilation prior to 5.0 everything was an emitted host
20477
20477
// function. In 5.0, no_host was introduced which might cause a function to
20478
- // be ommitted .
20478
+ // be omitted .
20479
20479
std::optional<OMPDeclareTargetDeclAttr::DevTypeTy> DevTy =
20480
20480
OMPDeclareTargetDeclAttr::getDeviceType(FD->getCanonicalDecl());
20481
20481
if (DevTy)
0 commit comments