Skip to content

Commit 8f2b167

Browse files
authored
[clang-tidy][NFC] Remove trailing whitespaces in documentation (#167103)
This is part of the codebase cleanup described in [#167098](#167098)
1 parent c8ab3b7 commit 8f2b167

33 files changed

+88
-88
lines changed

clang-tools-extra/docs/clang-tidy/checks/boost/use-ranges.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,7 @@ If calls are made using reverse iterators on containers, The code will be
146146
fixed using the ``boost::adaptors::reverse`` adaptor.
147147

148148
.. code-block:: c++
149-
149+
150150
auto AreSame = std::equal(Items1.rbegin(), Items1.rend(),
151151
std::crbegin(Items2), std::crend(Items2));
152152

@@ -166,7 +166,7 @@ Options
166166
is `llvm`.
167167

168168
.. option:: IncludeBoostSystem
169-
169+
170170
If `true` (default value) the boost headers are included as system headers
171171
with angle brackets (`#include <boost.hpp>`), otherwise quotes are used
172172
(`#include "boost.hpp"`).

clang-tools-extra/docs/clang-tidy/checks/bugprone/assignment-in-if-condition.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ Such assignments are bug-prone because they may have been intended as equality t
88

99
This check finds all assignments within `if` conditions, including ones that are not flagged
1010
by `-Wparentheses` due to an extra set of parentheses, and including assignments that call
11-
an overloaded `operator=()`. The identified assignments violate
11+
an overloaded `operator=()`. The identified assignments violate
1212
`BARR group "Rule 8.2.c" <https://barrgroup.com/embedded-systems/books/embedded-c-coding-standard/statement-rules/if-else-statements>`_.
1313

1414
.. code-block:: c++

clang-tools-extra/docs/clang-tidy/checks/bugprone/capturing-this-in-member-variable.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ Possible fixes:
3030
- marking copy and move constructors and assignment operators deleted.
3131
- using class member method instead of class member variable with function
3232
object types.
33-
- passing ``this`` pointer as parameter
33+
- passing ``this`` pointer as parameter.
3434

3535
Options
3636
-------

clang-tools-extra/docs/clang-tidy/checks/bugprone/crtp-constructor-accessibility.rst

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ bugprone-crtp-constructor-accessibility
66
Detects error-prone Curiously Recurring Template Pattern usage, when the CRTP
77
can be constructed outside itself and the derived class.
88

9-
The CRTP is an idiom, in which a class derives from a template class, where
9+
The CRTP is an idiom, in which a class derives from a template class, where
1010
itself is the template argument. It should be ensured that if a class is
1111
intended to be a base class in this idiom, it can only be instantiated if
1212
the derived class is its template argument.
@@ -23,7 +23,7 @@ Example:
2323

2424
class Derived : CRTP<Derived> {};
2525

26-
Below can be seen some common mistakes that will allow the breaking of the
26+
Below can be seen some common mistakes that will allow the breaking of the
2727
idiom.
2828

2929
If the constructor of a class intended to be used in a CRTP is public, then
@@ -62,7 +62,7 @@ Example:
6262
class Bad : CRTP<Good> {};
6363
Bad BadInstance;
6464

65-
To ensure that no accidental instantiation happens, the best practice is to
65+
To ensure that no accidental instantiation happens, the best practice is to
6666
make the constructor private and declare the derived class as friend. Note
6767
that as a tradeoff, this also gives the derived class access to every other
6868
private members of the CRTP. However, constructors can still be public or

clang-tools-extra/docs/clang-tidy/checks/bugprone/derived-method-shadowing-base-method.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ Finds derived class methods that shadow a (non-virtual) base class method.
77

88
In order to be considered "shadowing", methods must have the same signature
99
(i.e. the same name, same number of parameters, same parameter types, etc).
10-
Only checks public, non-templated methods.
10+
Only checks public, non-templated methods.
1111

1212
The below example is bugprone because consumers of the ``Derived`` class will
1313
expect the ``reset`` method to do the work of ``Base::reset()`` in addition to extra
@@ -27,4 +27,4 @@ This is also a violation of the Liskov Substitution Principle.
2727
2828
struct Derived : public Base {
2929
void reset() {/* reset the derived class, but not the base class */};
30-
};
30+
};

clang-tools-extra/docs/clang-tidy/checks/bugprone/incorrect-enable-shared-from-this.rst

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@
33
bugprone-incorrect-enable-shared-from-this
44
==========================================
55

6-
Detect classes or structs that do not publicly inherit from
7-
``std::enable_shared_from_this``, because unintended behavior will
6+
Detect classes or structs that do not publicly inherit from
7+
``std::enable_shared_from_this``, because unintended behavior will
88
otherwise occur when calling ``shared_from_this``.
99

1010
Consider the following code:
@@ -15,7 +15,7 @@ Consider the following code:
1515

1616
// private inheritance
1717
class BadExample : std::enable_shared_from_this<BadExample> {
18-
18+
1919
// ``shared_from_this``` unintended behaviour
2020
// `libstdc++` implementation returns uninitialized ``weak_ptr``
2121
public:
@@ -29,6 +29,6 @@ Consider the following code:
2929
b_ex->bar();
3030
}
3131

32-
Using `libstdc++` implementation, ``shared_from_this`` will throw
33-
``std::bad_weak_ptr``. When ``using_not_public()`` is called, this code will
32+
Using `libstdc++` implementation, ``shared_from_this`` will throw
33+
``std::bad_weak_ptr``. When ``using_not_public()`` is called, this code will
3434
crash without exception handling.

clang-tools-extra/docs/clang-tidy/checks/bugprone/pointer-arithmetic-on-polymorphic-object.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ Options
5454
Default: `false`.
5555

5656
.. code-block:: c++
57-
57+
5858
void bar(Base b[], Derived d[]) {
5959
b += 1; // warning, as Base declares a virtual destructor
6060
d += 1; // warning only if IgnoreVirtualDeclarationsOnly is set to false

clang-tools-extra/docs/clang-tidy/checks/bugprone/raw-memory-call-on-non-trivial-type.rst

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,17 +16,17 @@ Options
1616

1717
.. option:: MemSetNames
1818

19-
Specify extra functions to flag that act similarly to ``memset``. Specify
19+
Specify extra functions to flag that act similarly to ``memset``. Specify
2020
names in a semicolon-delimited list. Default is an empty string.
2121

2222
.. option:: MemCpyNames
2323

24-
Specify extra functions to flag that act similarly to ``memcpy``. Specify
24+
Specify extra functions to flag that act similarly to ``memcpy``. Specify
2525
names in a semicolon-delimited list. Default is an empty string.
2626

2727
.. option:: MemCmpNames
2828

29-
Specify extra functions to flag that act similarly to ``memcmp``. Specify
29+
Specify extra functions to flag that act similarly to ``memcmp``. Specify
3030
names in a semicolon-delimited list. Default is an empty string.
3131

3232
This check corresponds to the CERT C++ Coding Standard rule

clang-tools-extra/docs/clang-tidy/checks/bugprone/return-const-ref-from-parameter.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ Example
2222
S(int);
2323
~S();
2424
};
25-
25+
2626
const S &fn(const S &a) {
2727
return a;
2828
}
@@ -35,7 +35,7 @@ This issue can be resolved by declaring an overload of the problematic function
3535
where the ``const &`` parameter is instead declared as ``&&``. The developer has
3636
to ensure that the implementation of that function does not produce a
3737
use-after-free, the exact error that this check is warning against.
38-
Marking such an ``&&`` overload as ``deleted``, will silence the warning as
38+
Marking such an ``&&`` overload as ``deleted``, will silence the warning as
3939
well. In the case of different ``const &`` parameters being returned depending
4040
on the control flow of the function, an overload where all problematic
4141
``const &`` parameters have been declared as ``&&`` will resolve the issue.

clang-tools-extra/docs/clang-tidy/checks/bugprone/signal-handler.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ Options
4444

4545
Selects which set of functions is considered as asynchronous-safe
4646
(and therefore allowed in signal handlers). It can be set to the following values:
47-
47+
4848
``minimal``
4949
Selects a minimal set that is defined in the CERT SIG30-C rule.
5050
and includes functions ``abort()``, ``_Exit()``, ``quick_exit()`` and

0 commit comments

Comments
 (0)