Skip to content

Commit 0cd8232

Browse files
authored
Fix some typos (NFC) (#133558)
1 parent 9c6eca2 commit 0cd8232

11 files changed

+14
-14
lines changed

clang/docs/BoundsSafety.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -227,7 +227,7 @@ meaning they do not have ABI implications.
227227
annotated with ``__ended_by(Q)``. In this case, the end of the range extends
228228
to the pointer ``Q``. This is used for "iterator" support in C where you're
229229
iterating from one pointer value to another until a final pointer value is
230-
reached (and the final pointer value is not dereferencable).
230+
reached (and the final pointer value is not dereferenceable).
231231

232232
Accessing a pointer outside the specified bounds causes a run-time trap or a
233233
compile-time error. Also, the model maintains correctness of bounds annotations
@@ -507,7 +507,7 @@ Default pointer types in ``typeof()``
507507
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
508508

509509
When ``typeof()`` takes an expression, it respects the bounds annotation on
510-
the expression type, including the bounds annotation is implcit. For example,
510+
the expression type, including the bounds annotation is implicit. For example,
511511
the global variable ``g`` in the following code is implicitly ``__single`` so
512512
``typeof(g)`` gets ``char *__single``. The similar is true for the parameter
513513
``p``, so ``typeof(p)`` returns ``void *__single``. The local variable ``l`` is

clang/docs/ConstantInterpreter.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -293,4 +293,4 @@ TypeInfoPointer
293293

294294
``TypeInfoPointer`` tracks two types: the type assigned to
295295
``std::type_info`` and the type which was passed to ``typeinfo``.
296-
It is part of the taged union in ``Pointer``.
296+
It is part of the tagged union in ``Pointer``.

clang/docs/HIPSupport.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -704,7 +704,7 @@ Open Questions / Future Developments
704704
SPIR-V Support on HIPAMD ToolChain
705705
==================================
706706

707-
The HIPAMD ToolChain supports targetting
707+
The HIPAMD ToolChain supports targeting
708708
`AMDGCN Flavoured SPIR-V <https://llvm.org/docs/SPIRVUsage.html#target-triples>`_.
709709
The support for SPIR-V in the ROCm and HIPAMD ToolChain is under active
710710
development.

clang/docs/HLSL/AvailabilityDiagnostics.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ Strict Diagnostic Mode
4848

4949
When strict HLSL availability diagnostic mode is enabled the compiler must report all HLSL API availability issues regardless of code reachability. The implementation of this mode takes advantage of an existing diagnostic scan in ``DiagnoseUnguardedAvailability`` class which is already traversing AST of each function as soon as the function body has been parsed. For HLSL, this pass was only slightly modified, such as making sure diagnostic messages are in the ``hlsl-availability`` group and that availability checks based on shader stage are not included if the shader stage context is unknown.
5050

51-
If the compilation target is a shader library, only availability based on shader model version can be diagnosed during this scan. To diagnose availability based on shader stage, the compiler needs to run the AST traversals implementated in ``DiagnoseHLSLAvailability`` at the end of the translation unit as described above.
51+
If the compilation target is a shader library, only availability based on shader model version can be diagnosed during this scan. To diagnose availability based on shader stage, the compiler needs to run the AST traversals implemented in ``DiagnoseHLSLAvailability`` at the end of the translation unit as described above.
5252

5353
As a result, availability based on specific shader stage will only be diagnosed in code that is reachable from a shader entry point or library export function. It also means that function bodies might be scanned multiple time. When that happens, care should be taken not to produce duplicated diagnostics.
5454

clang/docs/MSVCCompatibility.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -240,7 +240,7 @@ In the above example ``hwPopCnt`` will not be inlined into ``PopCnt`` since ``Po
240240
With a larger function that does real work the function call overhead is negligible. However in our popcnt example there is the function call
241241
overhead. There is no analog for this specific MSVC behavior in clang.
242242

243-
For clang we effectively have to create the dispatch function ourselves to each specfic implementation.
243+
For clang we effectively have to create the dispatch function ourselves to each specific implementation.
244244

245245
SIMD vector types
246246
=================

clang/docs/SanitizerCoverage.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -314,7 +314,7 @@ will not be instrumented.
314314
void __sanitizer_cov_trace_div4(uint32_t Val);
315315
void __sanitizer_cov_trace_div8(uint64_t Val);
316316

317-
// Called before a GetElemementPtr (GEP) instruction
317+
// Called before a GetElementPtr (GEP) instruction
318318
// for every non-constant array index.
319319
void __sanitizer_cov_trace_gep(uintptr_t Idx);
320320

clang/unittests/Analysis/FlowSensitive/MultiVarConstantPropagationTest.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -167,8 +167,8 @@ class ConstantPropagationAnalysis
167167
? ValueLattice(R.Val.getInt().getExtValue())
168168
: ValueLattice::top();
169169
} else {
170-
// An unitialized variable holds *some* value, but we don't know what it
171-
// is (it is implementation defined), so we set it to top.
170+
// An uninitialized variable holds *some* value, but we don't know what
171+
// it is (it is implementation defined), so we set it to top.
172172
Vars[Var] = ValueLattice::top();
173173
}
174174
} else if (Nodes.getNodeAs<clang::Expr>(kJustAssignment)) {

clang/unittests/Analysis/FlowSensitive/TransferTest.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4888,7 +4888,7 @@ TEST(TransferTest, PointerEquality) {
48884888
48894889
// We won't duplicate all of the tests above with `!=`, as we know that
48904890
// the implementation simply negates the result of the `==` comparison.
4891-
// Instaed, just spot-check one case.
4891+
// Instead, just spot-check one case.
48924892
bool p1_ne_p1 = (p1 != p1);
48934893
48944894
(void)0; // [[p]]

clang/unittests/StaticAnalyzer/CallEventTest.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ void addCXXDeallocatorChecker(AnalysisASTConsumer &AnalysisConsumer,
6161
}
6262

6363
// TODO: What we should really be testing here is all the different varieties
64-
// of delete operators, and wether the retrieval of their arguments works as
64+
// of delete operators, and whether the retrieval of their arguments works as
6565
// intended. At the time of writing this file, CXXDeallocatorCall doesn't pick
6666
// up on much of those due to the AST not containing CXXDeleteExpr for most of
6767
// the standard/custom deletes.

clang/unittests/StaticAnalyzer/RegisterCustomCheckersTest.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -418,8 +418,8 @@ TEST(RegisterDeps, DependencyInteraction) {
418418

419419
// Weak dependencies are registered before strong dependencies. This is most
420420
// important for purely diagnostic checkers that are implemented as a part of
421-
// purely modeling checkers, becuse the checker callback order will have to be
422-
// established in between the modeling portion and the weak dependency.
421+
// purely modeling checkers, because the checker callback order will have to
422+
// be established in between the modeling portion and the weak dependency.
423423
EXPECT_TRUE(
424424
runCheckerOnCode<addWeakDepAndStrongDep>("void f() {int i;}", Diags));
425425
EXPECT_EQ(Diags, "test.RegistrationOrder: test.WeakDep\ntest."

clang/unittests/Tooling/ExecutionTest.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -214,7 +214,7 @@ TEST(StandaloneToolTest, SimpleActionWithResult) {
214214
auto KVs = Executor.getToolResults()->AllKVResults();
215215
ASSERT_EQ(KVs.size(), 1u);
216216
EXPECT_EQ("f", KVs[0].first);
217-
// Currently the standlone executor returns empty corpus, revision, and
217+
// Currently the standalone executor returns empty corpus, revision, and
218218
// compilation unit.
219219
EXPECT_EQ("::/1", KVs[0].second);
220220

0 commit comments

Comments
 (0)