forked from OSchip/llvm-project
d038faea46
This option allows callers to disable the warning from https://clang.llvm.org/extra/clang-tidy/checks/performance-move-const-arg.html that would warn on the following ``` void f(const string &s); string s; f(std::move(s)); // ALLOWED if performance-move-const-arg.CheckMoveToConstRef=false ``` The reason people might want to disable this check, is because it allows callers to use `std::move()` or not based on local reasoning about the argument, and without having to care about how the function `f` accepts the argument. Indeed, `f` might accept the argument by const-ref today, but change to by-value tomorrow, and if the caller had moved the argument that they were finished with, the code would work as efficiently as possible regardless of how `f` accepted the parameter. Reviewed By: ymandel Differential Revision: https://reviews.llvm.org/D119370 |
||
---|---|---|
.. | ||
checks | ||
Contributing.rst | ||
Integrations.rst | ||
index.rst |