[all-commits] [llvm/llvm-project] ed8ff2: [clang-tidy] Fix false positive in modernize-pass-...
Clement Courbet via All-commits
all-commits at lists.llvm.org
Wed Jan 5 05:34:03 PST 2022
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: ed8ff29aa6835187f3d5e7b64de022fe6b33a131
https://github.com/llvm/llvm-project/commit/ed8ff29aa6835187f3d5e7b64de022fe6b33a131
Author: Clement Courbet <courbet at google.com>
Date: 2022-01-05 (Wed, 05 Jan 2022)
Changed paths:
M clang-tools-extra/clang-tidy/modernize/PassByValueCheck.cpp
M clang-tools-extra/test/clang-tidy/checkers/modernize-pass-by-value.cpp
Log Message:
-----------
[clang-tidy] Fix false positive in modernize-pass-by-value
The check should not trigger on lvalue/rvalue overload pairs:
```
struct S {
S(const A& a) : a(a) {}
S(A&& a) : a(std::move(a)) {}
A a;
}
```
Differential Revision: https://reviews.llvm.org/D116535
More information about the All-commits
mailing list