[clang-tools-extra] [clang-tidy] add modernize-use-std-numbers (PR #66583)

Julian Schmidt via cfe-commits cfe-commits at lists.llvm.org
Tue Dec 5 10:40:33 PST 2023


================
@@ -193,6 +193,13 @@ New checks
   replacing with ``starts_with`` when the method exists in the class. Notably,
   this will work with ``std::string`` and ``std::string_view``.
 
+- New :doc:`modernize-use-std-numbers
+  <clang-tidy/checks/modernize/use-std-numbers>` check.
+
+  Finds constants and function calls to math functions that can be replaced
+  with c++20's mathematical constants from the ``numbers`` header and
----------------
5chmidti wrote:

Do you just want the `C` to be big, or do you want the version inside of single or double `?

https://github.com/llvm/llvm-project/pull/66583


More information about the cfe-commits mailing list