From 5fe4cd288ad41526078c2c47049c980831cea3e5 Mon Sep 17 00:00:00 2001 From: Niels Lohmann Date: Fri, 21 Aug 2026 04:09:21 +0200 Subject: [PATCH] Parenthesise the reserve() computation in the comparison test clang-tidy reports the mixed * and + as readability-math-missing- parentheses, as it does for the identical line in the copy test. Signed-off-by: Niels Lohmann --- tests/src/unit-large_json.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/src/unit-large_json.cpp b/tests/src/unit-large_json.cpp index 0f71bcd2e..3734966d5 100644 --- a/tests/src/unit-large_json.cpp +++ b/tests/src/unit-large_json.cpp @@ -188,7 +188,7 @@ TEST_CASE("tests on deeply nested JSONs") SECTION("comparing objects") { std::string text; - text.reserve(6 * depth + 1); + text.reserve((6 * depth) + 1); for (std::size_t i = 0; i < depth; ++i) { text += "{\"a\":";