From 8aae14931d4f3cb0ef529ba5f7e2e34d7bcc8e19 Mon Sep 17 00:00:00 2001 From: Daniel Lemire Date: Mon, 15 Sep 2025 09:17:43 -0600 Subject: [PATCH] release candidate 4.0.2 (#2441) * release candidate 4.0.2 * more fixes * fixing typos * adding macro check --- CMakeLists.txt | 2 +- Doxyfile | 2 +- .../generic/ondemand/std_deserialize.h | 56 +- include/simdjson/simdjson_version.h | 4 +- singleheader/simdjson.cpp | 2 +- singleheader/simdjson.h | 502 +++++++++++++----- singleheader/singleheader.zip | Bin 8230123 -> 8238963 bytes tests/dom/ranges_test.cpp | 3 +- 8 files changed, 420 insertions(+), 151 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 496116807..c8c027c7b 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -3,7 +3,7 @@ cmake_minimum_required(VERSION 3.14) project( simdjson # The version number is modified by tools/release.py - VERSION 4.0.1 + VERSION 4.0.2 DESCRIPTION "Parsing gigabytes of JSON per second" HOMEPAGE_URL "https://simdjson.org/" LANGUAGES CXX C diff --git a/Doxyfile b/Doxyfile index f071e00b6..02ffbef4a 100644 --- a/Doxyfile +++ b/Doxyfile @@ -38,7 +38,7 @@ PROJECT_NAME = simdjson # could be handy for archiving the generated documentation or if some version # control system is used. -PROJECT_NUMBER = "4.0.1" +PROJECT_NUMBER = "4.0.2" # Using the PROJECT_BRIEF tag one can provide an optional one line description # for a project that appears at the top of each page and should give viewer a diff --git a/include/simdjson/generic/ondemand/std_deserialize.h b/include/simdjson/generic/ondemand/std_deserialize.h index 96720ff59..c621a6247 100644 --- a/include/simdjson/generic/ondemand/std_deserialize.h +++ b/include/simdjson/generic/ondemand/std_deserialize.h @@ -253,7 +253,9 @@ error_code tag_invoke(deserialize_tag, auto &val, T &out) noexcept(nothrow_deser using value_type = typename std::remove_cvref_t::value_type; // Check if the value is null - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); // Set to nullopt return SUCCESS; } @@ -361,7 +363,9 @@ error_code tag_invoke(deserialize_tag, simdjson_value &val, std::shared_ptr & // Unique pointers //////////////////////////////////////// error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -374,7 +378,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) no } error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -387,7 +393,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) } error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -400,7 +408,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out } error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -413,7 +423,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) } error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -430,7 +442,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -443,7 +457,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) no } error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -456,7 +472,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) } error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -469,7 +487,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out } error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -482,7 +502,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) } error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -504,7 +526,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { // Check if the value is null - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); // Set to nullptr return SUCCESS; } @@ -520,7 +544,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr & error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { // Check if the value is null - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); // Set to nullptr return SUCCESS; } @@ -536,7 +562,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr & error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { // Check if the value is null - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); // Set to nullptr return SUCCESS; } diff --git a/include/simdjson/simdjson_version.h b/include/simdjson/simdjson_version.h index 900cc482d..4b6004b5f 100644 --- a/include/simdjson/simdjson_version.h +++ b/include/simdjson/simdjson_version.h @@ -4,7 +4,7 @@ #define SIMDJSON_SIMDJSON_VERSION_H /** The version of simdjson being used (major.minor.revision) */ -#define SIMDJSON_VERSION "4.0.1" +#define SIMDJSON_VERSION "4.0.2" namespace simdjson { enum { @@ -19,7 +19,7 @@ enum { /** * The revision (major.minor.REVISION) of simdjson being used. */ - SIMDJSON_VERSION_REVISION = 1 + SIMDJSON_VERSION_REVISION = 2 }; } // namespace simdjson diff --git a/singleheader/simdjson.cpp b/singleheader/simdjson.cpp index 4e51509bb..d1fc6b9b8 100644 --- a/singleheader/simdjson.cpp +++ b/singleheader/simdjson.cpp @@ -1,4 +1,4 @@ -/* auto-generated on 2025-09-12 19:26:22 -0400. version 4.0.1 Do not edit! */ +/* auto-generated on 2025-09-14 09:01:41 -0600. version 4.0.2 Do not edit! */ /* including simdjson.cpp: */ /* begin file simdjson.cpp */ #define SIMDJSON_SRC_SIMDJSON_CPP diff --git a/singleheader/simdjson.h b/singleheader/simdjson.h index 16a24068d..bf27830da 100644 --- a/singleheader/simdjson.h +++ b/singleheader/simdjson.h @@ -1,4 +1,4 @@ -/* auto-generated on 2025-09-12 19:26:22 -0400. version 4.0.1 Do not edit! */ +/* auto-generated on 2025-09-14 09:01:41 -0600. version 4.0.2 Do not edit! */ /* including simdjson.h: */ /* begin file simdjson.h */ #ifndef SIMDJSON_H @@ -2508,7 +2508,7 @@ namespace std { #define SIMDJSON_SIMDJSON_VERSION_H /** The version of simdjson being used (major.minor.revision) */ -#define SIMDJSON_VERSION "4.0.1" +#define SIMDJSON_VERSION "4.0.2" namespace simdjson { enum { @@ -2523,7 +2523,7 @@ enum { /** * The revision (major.minor.REVISION) of simdjson being used. */ - SIMDJSON_VERSION_REVISION = 1 + SIMDJSON_VERSION_REVISION = 2 }; } // namespace simdjson @@ -34086,7 +34086,9 @@ public: using value_type = typename std::remove_cvref_t::value_type; // Check if the value is null - if (is_null()) { + bool is_null_value; + SIMDJSON_TRY( is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); // Set to nullopt return SUCCESS; } @@ -38931,7 +38933,9 @@ error_code tag_invoke(deserialize_tag, auto &val, T &out) noexcept(nothrow_deser using value_type = typename std::remove_cvref_t::value_type; // Check if the value is null - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); // Set to nullopt return SUCCESS; } @@ -39039,7 +39043,9 @@ error_code tag_invoke(deserialize_tag, simdjson_value &val, std::shared_ptr & // Unique pointers //////////////////////////////////////// error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -39052,7 +39058,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) no } error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -39065,7 +39073,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) } error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -39078,7 +39088,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out } error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -39091,7 +39103,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) } error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -39108,7 +39122,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -39121,7 +39137,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) no } error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -39134,7 +39152,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) } error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -39147,7 +39167,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out } error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -39160,7 +39182,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) } error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -39182,7 +39206,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { // Check if the value is null - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); // Set to nullptr return SUCCESS; } @@ -39198,7 +39224,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr & error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { // Check if the value is null - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); // Set to nullptr return SUCCESS; } @@ -39214,7 +39242,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr & error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { // Check if the value is null - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); // Set to nullptr return SUCCESS; } @@ -45703,7 +45733,7 @@ simdjson_inline void string_builder::append_key_value(key_type key, value_type v #include #include -#include +#include #include #include #include @@ -47015,7 +47045,9 @@ public: using value_type = typename std::remove_cvref_t::value_type; // Check if the value is null - if (is_null()) { + bool is_null_value; + SIMDJSON_TRY( is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); // Set to nullopt return SUCCESS; } @@ -51860,7 +51892,9 @@ error_code tag_invoke(deserialize_tag, auto &val, T &out) noexcept(nothrow_deser using value_type = typename std::remove_cvref_t::value_type; // Check if the value is null - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); // Set to nullopt return SUCCESS; } @@ -51968,7 +52002,9 @@ error_code tag_invoke(deserialize_tag, simdjson_value &val, std::shared_ptr & // Unique pointers //////////////////////////////////////// error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -51981,7 +52017,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) no } error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -51994,7 +52032,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) } error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -52007,7 +52047,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out } error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -52020,7 +52062,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) } error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -52037,7 +52081,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -52050,7 +52096,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) no } error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -52063,7 +52111,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) } error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -52076,7 +52126,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out } error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -52089,7 +52141,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) } error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -52111,7 +52165,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { // Check if the value is null - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); // Set to nullptr return SUCCESS; } @@ -52127,7 +52183,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr & error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { // Check if the value is null - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); // Set to nullptr return SUCCESS; } @@ -52143,7 +52201,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr & error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { // Check if the value is null - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); // Set to nullptr return SUCCESS; } @@ -58632,7 +58692,7 @@ simdjson_inline void string_builder::append_key_value(key_type key, value_type v #include #include -#include +#include #include #include #include @@ -60443,7 +60503,9 @@ public: using value_type = typename std::remove_cvref_t::value_type; // Check if the value is null - if (is_null()) { + bool is_null_value; + SIMDJSON_TRY( is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); // Set to nullopt return SUCCESS; } @@ -65288,7 +65350,9 @@ error_code tag_invoke(deserialize_tag, auto &val, T &out) noexcept(nothrow_deser using value_type = typename std::remove_cvref_t::value_type; // Check if the value is null - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); // Set to nullopt return SUCCESS; } @@ -65396,7 +65460,9 @@ error_code tag_invoke(deserialize_tag, simdjson_value &val, std::shared_ptr & // Unique pointers //////////////////////////////////////// error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -65409,7 +65475,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) no } error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -65422,7 +65490,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) } error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -65435,7 +65505,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out } error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -65448,7 +65520,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) } error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -65465,7 +65539,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -65478,7 +65554,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) no } error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -65491,7 +65569,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) } error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -65504,7 +65584,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out } error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -65517,7 +65599,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) } error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -65539,7 +65623,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { // Check if the value is null - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); // Set to nullptr return SUCCESS; } @@ -65555,7 +65641,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr & error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { // Check if the value is null - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); // Set to nullptr return SUCCESS; } @@ -65571,7 +65659,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr & error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { // Check if the value is null - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); // Set to nullptr return SUCCESS; } @@ -72060,7 +72150,7 @@ simdjson_inline void string_builder::append_key_value(key_type key, value_type v #include #include -#include +#include #include #include #include @@ -73871,7 +73961,9 @@ public: using value_type = typename std::remove_cvref_t::value_type; // Check if the value is null - if (is_null()) { + bool is_null_value; + SIMDJSON_TRY( is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); // Set to nullopt return SUCCESS; } @@ -78716,7 +78808,9 @@ error_code tag_invoke(deserialize_tag, auto &val, T &out) noexcept(nothrow_deser using value_type = typename std::remove_cvref_t::value_type; // Check if the value is null - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); // Set to nullopt return SUCCESS; } @@ -78824,7 +78918,9 @@ error_code tag_invoke(deserialize_tag, simdjson_value &val, std::shared_ptr & // Unique pointers //////////////////////////////////////// error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -78837,7 +78933,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) no } error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -78850,7 +78948,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) } error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -78863,7 +78963,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out } error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -78876,7 +78978,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) } error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -78893,7 +78997,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -78906,7 +79012,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) no } error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -78919,7 +79027,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) } error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -78932,7 +79042,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out } error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -78945,7 +79057,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) } error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -78967,7 +79081,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { // Check if the value is null - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); // Set to nullptr return SUCCESS; } @@ -78983,7 +79099,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr & error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { // Check if the value is null - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); // Set to nullptr return SUCCESS; } @@ -78999,7 +79117,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr & error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { // Check if the value is null - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); // Set to nullptr return SUCCESS; } @@ -85488,7 +85608,7 @@ simdjson_inline void string_builder::append_key_value(key_type key, value_type v #include #include -#include +#include #include #include #include @@ -87414,7 +87534,9 @@ public: using value_type = typename std::remove_cvref_t::value_type; // Check if the value is null - if (is_null()) { + bool is_null_value; + SIMDJSON_TRY( is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); // Set to nullopt return SUCCESS; } @@ -92259,7 +92381,9 @@ error_code tag_invoke(deserialize_tag, auto &val, T &out) noexcept(nothrow_deser using value_type = typename std::remove_cvref_t::value_type; // Check if the value is null - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); // Set to nullopt return SUCCESS; } @@ -92367,7 +92491,9 @@ error_code tag_invoke(deserialize_tag, simdjson_value &val, std::shared_ptr & // Unique pointers //////////////////////////////////////// error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -92380,7 +92506,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) no } error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -92393,7 +92521,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) } error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -92406,7 +92536,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out } error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -92419,7 +92551,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) } error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -92436,7 +92570,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -92449,7 +92585,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) no } error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -92462,7 +92600,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) } error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -92475,7 +92615,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out } error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -92488,7 +92630,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) } error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -92510,7 +92654,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { // Check if the value is null - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); // Set to nullptr return SUCCESS; } @@ -92526,7 +92672,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr & error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { // Check if the value is null - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); // Set to nullptr return SUCCESS; } @@ -92542,7 +92690,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr & error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { // Check if the value is null - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); // Set to nullptr return SUCCESS; } @@ -99031,7 +99181,7 @@ simdjson_inline void string_builder::append_key_value(key_type key, value_type v #include #include -#include +#include #include #include #include @@ -101273,7 +101423,9 @@ public: using value_type = typename std::remove_cvref_t::value_type; // Check if the value is null - if (is_null()) { + bool is_null_value; + SIMDJSON_TRY( is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); // Set to nullopt return SUCCESS; } @@ -106118,7 +106270,9 @@ error_code tag_invoke(deserialize_tag, auto &val, T &out) noexcept(nothrow_deser using value_type = typename std::remove_cvref_t::value_type; // Check if the value is null - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); // Set to nullopt return SUCCESS; } @@ -106226,7 +106380,9 @@ error_code tag_invoke(deserialize_tag, simdjson_value &val, std::shared_ptr & // Unique pointers //////////////////////////////////////// error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -106239,7 +106395,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) no } error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -106252,7 +106410,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) } error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -106265,7 +106425,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out } error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -106278,7 +106440,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) } error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -106295,7 +106459,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -106308,7 +106474,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) no } error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -106321,7 +106489,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) } error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -106334,7 +106504,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out } error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -106347,7 +106519,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) } error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -106369,7 +106543,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { // Check if the value is null - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); // Set to nullptr return SUCCESS; } @@ -106385,7 +106561,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr & error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { // Check if the value is null - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); // Set to nullptr return SUCCESS; } @@ -106401,7 +106579,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr & error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { // Check if the value is null - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); // Set to nullptr return SUCCESS; } @@ -112890,7 +113070,7 @@ simdjson_inline void string_builder::append_key_value(key_type key, value_type v #include #include -#include +#include #include #include #include @@ -114609,7 +114789,9 @@ public: using value_type = typename std::remove_cvref_t::value_type; // Check if the value is null - if (is_null()) { + bool is_null_value; + SIMDJSON_TRY( is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); // Set to nullopt return SUCCESS; } @@ -119454,7 +119636,9 @@ error_code tag_invoke(deserialize_tag, auto &val, T &out) noexcept(nothrow_deser using value_type = typename std::remove_cvref_t::value_type; // Check if the value is null - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); // Set to nullopt return SUCCESS; } @@ -119562,7 +119746,9 @@ error_code tag_invoke(deserialize_tag, simdjson_value &val, std::shared_ptr & // Unique pointers //////////////////////////////////////// error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -119575,7 +119761,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) no } error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -119588,7 +119776,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) } error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -119601,7 +119791,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out } error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -119614,7 +119806,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) } error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -119631,7 +119825,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -119644,7 +119840,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) no } error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -119657,7 +119855,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) } error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -119670,7 +119870,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out } error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -119683,7 +119885,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) } error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -119705,7 +119909,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { // Check if the value is null - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); // Set to nullptr return SUCCESS; } @@ -119721,7 +119927,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr & error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { // Check if the value is null - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); // Set to nullptr return SUCCESS; } @@ -119737,7 +119945,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr & error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { // Check if the value is null - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); // Set to nullptr return SUCCESS; } @@ -126226,7 +126436,7 @@ simdjson_inline void string_builder::append_key_value(key_type key, value_type v #include #include -#include +#include #include #include #include @@ -127958,7 +128168,9 @@ public: using value_type = typename std::remove_cvref_t::value_type; // Check if the value is null - if (is_null()) { + bool is_null_value; + SIMDJSON_TRY( is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); // Set to nullopt return SUCCESS; } @@ -132803,7 +133015,9 @@ error_code tag_invoke(deserialize_tag, auto &val, T &out) noexcept(nothrow_deser using value_type = typename std::remove_cvref_t::value_type; // Check if the value is null - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); // Set to nullopt return SUCCESS; } @@ -132911,7 +133125,9 @@ error_code tag_invoke(deserialize_tag, simdjson_value &val, std::shared_ptr & // Unique pointers //////////////////////////////////////// error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -132924,7 +133140,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) no } error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -132937,7 +133155,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) } error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -132950,7 +133170,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out } error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -132963,7 +133185,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) } error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -132980,7 +133204,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -132993,7 +133219,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) no } error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -133006,7 +133234,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) } error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -133019,7 +133249,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out } error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -133032,7 +133264,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) } error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); return SUCCESS; } @@ -133054,7 +133288,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { // Check if the value is null - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); // Set to nullptr return SUCCESS; } @@ -133070,7 +133306,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr & error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr &out) noexcept { // Check if the value is null - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); // Set to nullptr return SUCCESS; } @@ -133086,7 +133324,9 @@ error_code tag_invoke(deserialize_tag, auto &val, std::shared_ptr & error_code tag_invoke(deserialize_tag, auto &val, std::unique_ptr &out) noexcept { // Check if the value is null - if (val.is_null()) { + bool is_null_value; + SIMDJSON_TRY( val.is_null().get(is_null_value) ); + if (is_null_value) { out.reset(); // Set to nullptr return SUCCESS; } @@ -139575,7 +139815,7 @@ simdjson_inline void string_builder::append_key_value(key_type key, value_type v #include #include -#include +#include #include #include #include diff --git a/singleheader/singleheader.zip b/singleheader/singleheader.zip index 6acc67467c77a2655b51cacdff874ef36100eb25..e2bbc04ec76d08bb32e4348388abcea7eeed7a06 100644 GIT binary patch delta 10489 zcmeI2YfO_@7=Wdfo7`%-iD3D-IEw-nM34%$pg1lops>nC`HENpsaQc#=5XxC$rrQa z2%F>0HZR>KON@(`Om}AZAu;a9GUp8Y;dCn1m@M7^HIn_9W^XT;m~J@T=MR^!$@Al+ z?c4L6^n1Sdeb2dbXk7kqWL&N+FOg3To8ox2kks0tO*+!6%#6+8G}&5Bnl>YiOVMO% zG^t#Nxvjl0|^Zx zG?>s3LKTEgCsavjD4}75h7%e=Xe6OC2#q3iCZW-U#t=G-P!*xEgmQ$&5gJcu!bzHV z=F1Sr1V6JJ@90uiPeFh`n3(dsnF=^lcKG1zs0Fh0_>a=kBH7i8vsZd~r9yXpzM%?o>|HQm7nlPgum^ zH&dS<(<2_l`Q?VOF=DjH;Piu>SQxb%7QyY`bEbpoWKIaXx}-op4F<2*`+)6M^{kiv z9d^I4Ai+zFK)rVjYB2%<&d3Pdh+#;SS@jt;;?1fju_=J<56)d6O335oc%i0+{7+(B zCDG#%)*yb^w{ zDi{|t>~f~7DTwoe$E&jah4az5$Pz?{=-K(`yc=NmPX z%8+t)?(vGKD3|Rnr~<=;(a4o-G_vATwP<#;4Od$FzNv8MZ&$RHdgsU~xcAa4W&pbF z2e4kRoB^7wx?tEXFG+^(LlvQ5y;b7y#*HR_>GAW}}$-dyKIl5R+lgEil_SjmZFW5shQw4Ls5m|*)A=S*>UlZ*1 zpe;xd2IWmP0ql;k!KMPmt{^`_bFBt6*J=Yr)1v0jnpn^e)fGWc_Zqhx_ZHRVxQ0$U za(nBh_g$#q zG2bXMA#_m@U1d0Zmd%&#}KWdDBH|={;u;&h!44wk`f?ztVH9p1Sf? zw)EWF7CrUr0)+u}6Vi-qKw8*<+L9RUs&{QU5#g}=$CioiUeBWjf40BDa&JU5(%jD|)nz(i-@rzsmF*kY^oLj#ET(X(53IACyR>XapEXWO;UvjTSYGPq{oOH&NwoAD zrEsyCo$+3vxoq(PEM`mL%7eBf7|iM{f(^Nw)wpkJ4Pd6Pj33HjY;l{49Vp=E%!I)e z?Q7w}2CEO~f3b#x{f0G6*g0fHHY06p=TLj?eTN=z!NB1g$!Ev1hdcS3yJef!HFPF_oUTLQblVuG+YTZYxw#>oDwiSm&+Lqs3@I5>GUWfh$Q96# s$UDdmk%_w zahp6JmLZEQ%c5aq8NSJuIl`yKp%%@&Wo&Fqwk&3Y>|(Md;-0pQgjwo0-3OZdlJ`C5 zIp;h*??38f3@r?6V@wTc`b)&uFv?L=gO|HqxPRqznOOvOl zH>lOA^6tj{2U3{awfR3SvU3PZ22$q?iw1IH#Q|^lQ z2yv+Py7vgjCGIg1pZ{gN>-8Q?o^IVFSSG{_{SvLGEE)cfq~)&?XIhub%REq7;3*?E zHDa#!@%(;U7#FJ*3LZVl!mo0zo{r<9oDjf+vMeF5l53Go$Yw;xRPrs~M}##V;u`n2 zv^BPO*4fs>=A%1)KBM!OfF-g%gxPKNLoygI4+vnNlx&H5&yz^_@x6K^kB#rm|7iNr z%ob%a9lFfBU6H{Pk^wJjC_uI%+mP){)UZPxyHo)@Du8W1`ch52r^N=7PN;ynvYbq? z=kJU;7GgLSvh!kyQS-Hzg-1Ua`NpVl`2k$HZj=t3HHuh&R*&zBF?h1YCuj`(WN;y} z3o#)@Y%;hwI(n%hT%G_9S!e_do-YbzAGYPey*|EMbba}TF z>;q-t(Er`eqs(E|s|8@3D3t;?U*ZpQH!TuSPn2fCrqNDHB}Wkqm={EhOMpv##Y28sDY>}`{YWQKFCn5Zn5ihtJ~_hqUKna)$wR`NE0&|n#XQA>9__dw@${h?}@TjSobJs9N_ zD@u6EO5kg!IOJtyKXQQ8PIZ1J_EewxPsWHB8?zx9n-FwG{I*mJ&fWYQR#5l#q(kkw zgK3~X)+L0iU$q7C+UjoPAk$VK^1b6-A(N>+GItOEx1vW3we;{xD>H92!~bN9Z#mo* z#82<(L0&-)BS+Zup594`C)McsWZ{dd*}fy_-|uSh@M3S;BOkGJtT!c~{;gj80QV17 C5uT|4 diff --git a/tests/dom/ranges_test.cpp b/tests/dom/ranges_test.cpp index 73bec2cd4..18298d6a3 100644 --- a/tests/dom/ranges_test.cpp +++ b/tests/dom/ranges_test.cpp @@ -8,7 +8,7 @@ using namespace simdjson; namespace ranges_test { - +#if SIMDJSON_EXCEPTIONS bool printout() { TEST_START(); auto cars_json = R"( [ @@ -43,6 +43,7 @@ namespace ranges_test { ASSERT_TRUE(std::ranges::equal(cars, expected)); TEST_SUCCEED(); } + #endif // SIMDJSON_EXCEPTIONS bool run() { return