1
0
mirror of https://github.com/nlohmann/json.git synced 2025-07-29 23:01:16 +03:00

🚨 fix warning

This commit is contained in:
Niels Lohmann
2021-08-01 14:08:14 +02:00
parent 5a1bc76f34
commit c3df4ffd5a
2 changed files with 2 additions and 0 deletions

View File

@ -908,6 +908,7 @@ class binary_writer
if (JSON_HEDLEY_UNLIKELY(it != BasicJsonType::string_t::npos))
{
JSON_THROW(out_of_range::create(409, "BSON key cannot contain code point U+0000 (at byte " + std::to_string(it) + ")", j));
static_cast<void>(j);
}
return /*id*/ 1ul + name.size() + /*zero-terminator*/1u;

View File

@ -14209,6 +14209,7 @@ class binary_writer
if (JSON_HEDLEY_UNLIKELY(it != BasicJsonType::string_t::npos))
{
JSON_THROW(out_of_range::create(409, "BSON key cannot contain code point U+0000 (at byte " + std::to_string(it) + ")", j));
static_cast<void>(j);
}
return /*id*/ 1ul + name.size() + /*zero-terminator*/1u;