[PATCH] D116535: [clang-tidy] Fix false positive in modernize-pass-by-value
Clement Courbet via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Mon Jan 3 05:46:45 PST 2022
courbet created this revision.
courbet added reviewers: alexfh, flx, aaron.ballman.
Herald added subscribers: carlosgalvezp, xazax.hun.
courbet requested review of this revision.
Herald added a project: clang-tools-extra.
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;
}
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D116535
Files:
clang-tools-extra/clang-tidy/modernize/PassByValueCheck.cpp
clang-tools-extra/test/clang-tidy/checkers/modernize-pass-by-value.cpp
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D116535.397050.patch
Type: text/x-patch
Size: 4121 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20220103/ef9e60c5/attachment.bin>
More information about the cfe-commits
mailing list