[clang] cppcheck: pass NodeKinds by const reference (PR #87273)

2024-04-01 Thread Amila Senadheera via cfe-commits
https://github.com/Amila-Rukshan updated https://github.com/llvm/llvm-project/pull/87273 >From 4f8349936403d29ac14179fb7d9e1429a09914ff Mon Sep 17 00:00:00 2001 From: amila Date: Tue, 2 Apr 2024 00:15:59 +0530 Subject: [PATCH] use move semantics for NodeKinds and update possible callers to use

[clang] cppcheck: pass NodeKinds by const reference (PR #87273)

2024-04-01 Thread Oliver Stöneberg via cfe-commits
firewave wrote: Depending on the calling code the fix might actually be the introduction of `std::move()`. This is a known issue upstream: https://trac.cppcheck.net/ticket/12384. https://github.com/llvm/llvm-project/pull/87273 ___ cfe-commits mailing

[clang] cppcheck: pass NodeKinds by const reference (PR #87273)

2024-04-01 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Amila Senadheera (Amila-Rukshan) Changes Fix the cppcheck identified performance issue: https://github.com/llvm/llvm-project/issues/87248 I ran the following to check the possible perf issue in `clang/lib/ASTMatchers/Dynamic` directory:

[clang] cppcheck: pass NodeKinds by const reference (PR #87273)

2024-04-01 Thread via cfe-commits
github-actions[bot] wrote: Thank you for submitting a Pull Request (PR) to the LLVM Project! This PR will be automatically labeled and the relevant teams will be notified. If you wish to, you can add reviewers by using the "Reviewers" section on this page. If this is not working for you, it

[clang] cppcheck: pass NodeKinds by const reference (PR #87273)

2024-04-01 Thread Amila Senadheera via cfe-commits
https://github.com/Amila-Rukshan created https://github.com/llvm/llvm-project/pull/87273 Fix the cppcheck identified performance issue: https://github.com/llvm/llvm-project/issues/87248 I ran the following to check the possible perf issue in `clang/lib/ASTMatchers/Dynamic` directory: ``` cppc