Skip to content

Commit 8b7f81f

Browse files
authored
[NFC] Fix assignment typo. (#151864)
1 parent fca9f70 commit 8b7f81f

File tree

15 files changed

+18
-18
lines changed

15 files changed

+18
-18
lines changed

clang-tools-extra/test/clang-tidy/checkers/performance/unnecessary-value-param.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -285,9 +285,9 @@ struct NotCopyAssigned {
285285
NotCopyAssigned &operator=(const ExpensiveMovableType &);
286286
};
287287

288-
void PositiveNoMoveForNonCopyAssigmentOperator(ExpensiveMovableType E) {
289-
// CHECK-MESSAGES: [[@LINE-1]]:69: warning: the parameter 'E' is copied
290-
// CHECK-FIXES: void PositiveNoMoveForNonCopyAssigmentOperator(const ExpensiveMovableType& E) {
288+
void PositiveNoMoveForNonCopyAssignmentOperator(ExpensiveMovableType E) {
289+
// CHECK-MESSAGES: [[@LINE-1]]:70: warning: the parameter 'E' is copied
290+
// CHECK-FIXES: void PositiveNoMoveForNonCopyAssignmentOperator(const ExpensiveMovableType& E) {
291291
NotCopyAssigned N;
292292
N = E;
293293
}

clang/include/clang/Sema/SemaHLSL.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@ struct DeclBindingInfo {
8484

8585
// ResourceBindings class stores information about all resource bindings
8686
// in a shader. It is used for binding diagnostics and implicit binding
87-
// assigments.
87+
// assignments.
8888
class ResourceBindings {
8989
public:
9090
DeclBindingInfo *addDeclBindingInfo(const VarDecl *VD,

clang/test/CXX/dcl.dcl/dcl.spec/dcl.type/dcl.spec.auto/p4.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ const auto S::c = 0;
4646
namespace std { template<typename T> struct initializer_list { const T *a, *b; initializer_list(); }; }
4747

4848
// In an initializer of the form ( expression-list ), the expression-list
49-
// shall be a single assigment-expression.
49+
// shall be a single assignment-expression.
5050
auto parens1(1);
5151
auto parens2(2, 3); // expected-error {{initializer for variable 'parens2' with type 'auto' contains multiple expressions}}
5252
#if __cplusplus >= 201103L

clang/test/SemaCXX/warn-self-assign-builtin.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ void false_positives() {
4848
vol_a_ref = vol_a_ref;
4949
}
5050

51-
// Do not diagnose self-assigment in an unevaluated context
51+
// Do not diagnose self-assignment in an unevaluated context
5252
void false_positives_unevaluated_ctx(int a) noexcept(noexcept(a = a)) // expected-warning {{expression with side effects has no effect in an unevaluated context}}
5353
{
5454
decltype(a = a) b = a; // expected-warning {{expression with side effects has no effect in an unevaluated context}}

clang/test/SemaCXX/warn-self-assign-field-builtin.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ struct C {
5252
a = (int &)a;
5353
}
5454

55-
// Do not diagnose self-assigment in an unevaluated context
55+
// Do not diagnose self-assignment in an unevaluated context
5656
void false_positives_unevaluated_ctx() noexcept(noexcept(a = a)) // expected-warning {{expression with side effects has no effect in an unevaluated context}}
5757
{
5858
decltype(a = a) b = a; // expected-warning {{expression with side effects has no effect in an unevaluated context}}

clang/test/SemaCXX/warn-self-assign-field-overloaded.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ struct C {
100100
#endif
101101
};
102102

103-
// Do not diagnose self-assigment in an unevaluated context
103+
// Do not diagnose self-assignment in an unevaluated context
104104
struct SNoExcept {
105105
SNoExcept() = default;
106106
SNoExcept &operator=(const SNoExcept &) noexcept;

clang/test/SemaCXX/warn-self-assign-overloaded.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ void false_positives() {
9393
#endif
9494
}
9595

96-
// Do not diagnose self-assigment in an unevaluated context
96+
// Do not diagnose self-assignment in an unevaluated context
9797
struct SNoExcept {
9898
SNoExcept() = default;
9999
SNoExcept &operator=(const SNoExcept &) noexcept;

clang/unittests/Format/FormatTest.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7558,7 +7558,7 @@ TEST_F(FormatTest, NoOperandAlignment) {
75587558
Style);
75597559
}
75607560

7561-
TEST_F(FormatTest, BreakingBeforeNonAssigmentOperators) {
7561+
TEST_F(FormatTest, BreakingBeforeNonAssignmentOperators) {
75627562
FormatStyle Style = getLLVMStyle();
75637563
Style.BreakBeforeBinaryOperators = FormatStyle::BOS_NonAssignment;
75647564
verifyFormat("int aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa =\n"

flang-rt/include/flang-rt/runtime/type-info.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -179,7 +179,7 @@ class SpecialBinding {
179179
// The passed-object argument (usually the "to") is always passed via a
180180
// a descriptor in the cases where the runtime will call a defined
181181
// assignment because these calls are to type-bound generics,
182-
// not generic interfaces, and type-bound generic defined assigment
182+
// not generic interfaces, and type-bound generic defined assignment
183183
// may appear only in an extensible type and requires a passed-object
184184
// argument (see C774), and passed-object arguments to TBPs must be
185185
// both polymorphic and scalar (C760). The non-passed-object argument

0 commit comments

Comments
 (0)