mirror of
https://github.com/nlohmann/json.git
synced 2026-08-22 17:13:18 +00:00
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 <mail@nlohmann.me>
This commit is contained in:
@@ -188,7 +188,7 @@ TEST_CASE("tests on deeply nested JSONs")
|
|||||||
SECTION("comparing objects")
|
SECTION("comparing objects")
|
||||||
{
|
{
|
||||||
std::string text;
|
std::string text;
|
||||||
text.reserve(6 * depth + 1);
|
text.reserve((6 * depth) + 1);
|
||||||
for (std::size_t i = 0; i < depth; ++i)
|
for (std::size_t i = 0; i < depth; ++i)
|
||||||
{
|
{
|
||||||
text += "{\"a\":";
|
text += "{\"a\":";
|
||||||
|
|||||||
Reference in New Issue
Block a user