mirror of
https://github.com/nlohmann/json.git
synced 2026-10-19 04:28:12 +00:00
📝 release preparation
This commit is contained in:
7 files changed
+175
-37
No files matched your search
@@ -80,8 +80,10 @@ class binary_reader
|
||||
result = parse_ubjson_internal();
|
||||
break;
|
||||
|
||||
// LCOV_EXCL_START
|
||||
default:
|
||||
assert(false); // LCOV_EXCL_LINE
|
||||
assert(false);
|
||||
// LCOV_EXCL_STOP
|
||||
}
|
||||
|
||||
// strict mode: next byte must be EOF
|
||||
|
||||
@@ -249,16 +249,18 @@ class json_sax_dom_parser
|
||||
{
|
||||
case 1:
|
||||
JSON_THROW(*reinterpret_cast<const detail::parse_error*>(&ex));
|
||||
case 2:
|
||||
JSON_THROW(*reinterpret_cast<const detail::invalid_iterator*>(&ex)); // LCOV_EXCL_LINE
|
||||
case 3:
|
||||
JSON_THROW(*reinterpret_cast<const detail::type_error*>(&ex)); // LCOV_EXCL_LINE
|
||||
case 4:
|
||||
JSON_THROW(*reinterpret_cast<const detail::out_of_range*>(&ex));
|
||||
// LCOV_EXCL_START
|
||||
case 2:
|
||||
JSON_THROW(*reinterpret_cast<const detail::invalid_iterator*>(&ex));
|
||||
case 3:
|
||||
JSON_THROW(*reinterpret_cast<const detail::type_error*>(&ex));
|
||||
case 5:
|
||||
JSON_THROW(*reinterpret_cast<const detail::other_error*>(&ex)); // LCOV_EXCL_LINE
|
||||
JSON_THROW(*reinterpret_cast<const detail::other_error*>(&ex));
|
||||
default:
|
||||
assert(false); // LCOV_EXCL_LINE
|
||||
assert(false);
|
||||
// LCOV_EXCL_STOP
|
||||
}
|
||||
}
|
||||
return false;
|
||||
@@ -505,16 +507,18 @@ class json_sax_dom_callback_parser
|
||||
{
|
||||
case 1:
|
||||
JSON_THROW(*reinterpret_cast<const detail::parse_error*>(&ex));
|
||||
case 2:
|
||||
JSON_THROW(*reinterpret_cast<const detail::invalid_iterator*>(&ex)); // LCOV_EXCL_LINE
|
||||
case 3:
|
||||
JSON_THROW(*reinterpret_cast<const detail::type_error*>(&ex)); // LCOV_EXCL_LINE
|
||||
case 4:
|
||||
JSON_THROW(*reinterpret_cast<const detail::out_of_range*>(&ex));
|
||||
// LCOV_EXCL_START
|
||||
case 2:
|
||||
JSON_THROW(*reinterpret_cast<const detail::invalid_iterator*>(&ex));
|
||||
case 3:
|
||||
JSON_THROW(*reinterpret_cast<const detail::type_error*>(&ex));
|
||||
case 5:
|
||||
JSON_THROW(*reinterpret_cast<const detail::other_error*>(&ex)); // LCOV_EXCL_LINE
|
||||
JSON_THROW(*reinterpret_cast<const detail::other_error*>(&ex));
|
||||
default:
|
||||
assert(false); // LCOV_EXCL_LINE
|
||||
assert(false);
|
||||
// LCOV_EXCL_STOP
|
||||
}
|
||||
}
|
||||
return false;
|
||||
|
||||
@@ -92,8 +92,10 @@ class lexer
|
||||
return "end of input";
|
||||
case token_type::literal_or_value:
|
||||
return "'[', '{', or a literal";
|
||||
// LCOV_EXCL_START
|
||||
default: // catch non-enum values
|
||||
return "unknown token"; // LCOV_EXCL_LINE
|
||||
return "unknown token";
|
||||
// LCOV_EXCL_STOP
|
||||
}
|
||||
}
|
||||
|
||||
@@ -745,11 +747,13 @@ class lexer
|
||||
goto scan_number_any1;
|
||||
}
|
||||
|
||||
// LCOV_EXCL_START
|
||||
default:
|
||||
{
|
||||
// all other characters are rejected outside scan_number()
|
||||
assert(false); // LCOV_EXCL_LINE
|
||||
assert(false);
|
||||
}
|
||||
// LCOV_EXCL_STOP
|
||||
}
|
||||
|
||||
scan_number_minus:
|
||||
|
||||
Reference in new issue
Block a user