[clang-tools-extra] [clang-tidy][cppcoreguidelines-missing-std-forward] Do not warn when the parameter is used in a `static_cast<T&>`. (PR #99477)
Julian Schmidt via cfe-commits
cfe-commits at lists.llvm.org
Sun Oct 13 09:50:23 PDT 2024
================
@@ -38,3 +38,12 @@ Example:
This check implements `F.19
<http://isocpp.github.io/CppCoreGuidelines/CppCoreGuidelines#Rf-forward>`_
from the C++ Core Guidelines.
+
+Options
+-------
+
+.. option:: IgnoreStaticCasts
+
+ Boolean flag to allow users who want to use the forwarding reference as an
+ lvalue reference to convey he intention by using ``static_cast<T&>(t)`` to
+ disable warning. Default value is `false`.
----------------
5chmidti wrote:
`to convey the intention`
+
`, disabling the warning`
https://github.com/llvm/llvm-project/pull/99477
More information about the cfe-commits
mailing list