From 8d896613a7913f265c532aa5d951dcc4c0b413f1 Mon Sep 17 00:00:00 2001 From: Fredrik Sandhei Date: Tue, 19 Mar 2024 20:59:18 +0100 Subject: [PATCH] amalgamate --- single_include/nlohmann/json.hpp | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/single_include/nlohmann/json.hpp b/single_include/nlohmann/json.hpp index bb2cbb8f3..937a5fc00 100644 --- a/single_include/nlohmann/json.hpp +++ b/single_include/nlohmann/json.hpp @@ -22913,8 +22913,6 @@ class basic_json // NOLINT(cppcoreguidelines-special-member-functions,hicpp-spec #endif } - // template::value, int>::type = 0> /// @brief comparison: equal /// @sa https://json.nlohmann.me/api/basic_json/operator_eq/ template @@ -22924,6 +22922,15 @@ class basic_json // NOLINT(cppcoreguidelines-special-member-functions,hicpp-spec return *this == basic_json(rhs); } + /// @brief comparison: not equal + /// @sa https://json.nlohmann.me/api/basic_json/operator_eq/ + template + requires detail::json_compatible_type::value + bool operator!=(T rhs) const noexcept + { + return *this != basic_json(rhs); + } + /// @sa https://json.nlohmann.me/api/basic_json/operator_eq/ bool operator==(std::nullptr_t rhs) const noexcept {