[clang-tools-extra] [clang-tidy] Fix performance-move-const-arg false negative in ternary… (PR #128402)
David Rivera via cfe-commits
cfe-commits at lists.llvm.org
Sun Feb 23 08:27:10 PST 2025
================
@@ -44,6 +44,12 @@ void MoveConstArgCheck::registerMatchers(MatchFinder *Finder) {
unless(isInTemplateInstantiation()))
.bind("call-move");
+ // Match ternary expressions where either branch contains std::move
+ auto TernaryWithMoveMatcher =
+ conditionalOperator(
+ hasDescendant(MoveCallMatcher)
+ ).bind("ternary-move");
----------------
RiverDave wrote:
Amazing! Appreciate your feedback, all of your comments should be addressed by now.
https://github.com/llvm/llvm-project/pull/128402
More information about the cfe-commits
mailing list