From fee04d926bd6506b8668081ce326c6350a9d9ba3 Mon Sep 17 00:00:00 2001 From: Niels Lohmann Date: Sat, 23 Sep 2023 12:32:51 +0200 Subject: [PATCH] :rotating_light: fix warnings --- .clang-tidy | 1 + include/nlohmann/detail/input/lexer.hpp | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/.clang-tidy b/.clang-tidy index 1b0fff5ce..b874192d9 100644 --- a/.clang-tidy +++ b/.clang-tidy @@ -45,6 +45,7 @@ Checks: '*, -modernize-type-traits, -modernize-use-nodiscard, -modernize-use-trailing-return-type, + -performance-enum-size, -readability-function-cognitive-complexity, -readability-function-size, -readability-identifier-length, diff --git a/include/nlohmann/detail/input/lexer.hpp b/include/nlohmann/detail/input/lexer.hpp index 72e995108..50fc9df59 100644 --- a/include/nlohmann/detail/input/lexer.hpp +++ b/include/nlohmann/detail/input/lexer.hpp @@ -222,7 +222,7 @@ class lexer : public lexer_base for (auto range = ranges.begin(); range != ranges.end(); ++range) { get(); - if (JSON_HEDLEY_LIKELY(*range <= current && current <= *(++range))) + if (JSON_HEDLEY_LIKELY(*range <= current && current <= *(++range))) // NOLINT(bugprone-inc-dec-in-conditions) { add(current); }