[clang-tools-extra] Add clang-tidy check to suggest replacement of conditional statement with std::min/std::max (PR #77816)

Piotr Zegar via cfe-commits cfe-commits at lists.llvm.org
Thu Jan 11 11:06:43 PST 2024


================
@@ -62,6 +63,8 @@ namespace readability {
 class ReadabilityModule : public ClangTidyModule {
 public:
   void addCheckFactories(ClangTidyCheckFactories &CheckFactories) override {
+    CheckFactories.registerCheck<ConditionaltostdminmaxCheck>(
+        "readability-ConditionalToStdMinMax");
----------------
PiotrZSL wrote:

name should be: readability-use-min-max or readability-use-std-min-max or modernize-use-min-max

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


More information about the cfe-commits mailing list