mirror of
https://github.com/nlohmann/json.git
synced 2026-10-04 13:40:33 +00:00
Defining JSON_DELETE_DEPRECATED_FUNCTIONS to 1 (or the CMake option JSON_DeleteDeprecatedFunctions) declares every deprecated function as deleted instead of deprecated, so that code that is not ready for 4.0.0 no longer compiles. A deleted function still takes part in overload resolution, so from_*(ptr, len) cannot silently bind len to the strict parameter of from_*(InputType&&, bool); the roadmap now plans to keep these overloads deleted in 4.0.0 instead of removing them. The legacy discarded-value comparison is left to its own macro. Also update the 4.0 roadmap: add JSON_DISABLE_TUPLE_REFERENCE_CONVERSION and JSON_DELETE_DEPRECATED_FUNCTIONS to the macro table, add the from_bjdata/from_bon8 (ptr, len) overloads to the deprecated functions, document the macro in the migration guide, and fix the docs style check findings (example titles, missing docset entry for JSON_STRICT_BINARY_UTF8). Signed-off-by: Niels Lohmann <mail@nlohmann.me>
50 lines
1.5 KiB
C++
50 lines
1.5 KiB
C++
// __ _____ _____ _____
|
|
// __| | __| | | | JSON for Modern C++
|
|
// | | |__ | | | | | | version 3.12.0
|
|
// |_____|_____|_____|_|___| https://github.com/nlohmann/json
|
|
//
|
|
// SPDX-FileCopyrightText: 2013-2026 Niels Lohmann <https://nlohmann.me>
|
|
// SPDX-License-Identifier: MIT
|
|
|
|
#pragma once
|
|
|
|
// clean up
|
|
#undef JSON_ASSERT
|
|
#undef JSON_INTERNAL_CATCH
|
|
#undef JSON_THROW
|
|
#undef JSON_PRIVATE_UNLESS_TESTED
|
|
#undef NLOHMANN_BASIC_JSON_TPL_DECLARATION
|
|
#undef NLOHMANN_BASIC_JSON_TPL
|
|
#undef JSON_EXPLICIT
|
|
#undef NLOHMANN_CAN_CALL_STD_FUNC_IMPL
|
|
#undef JSON_INLINE_VARIABLE
|
|
#undef JSON_NO_UNIQUE_ADDRESS
|
|
#undef JSON_DISABLE_ENUM_SERIALIZATION
|
|
#undef JSON_DISABLE_TUPLE_REFERENCE_CONVERSION
|
|
|
|
#ifndef JSON_TEST_KEEP_MACROS
|
|
#undef JSON_CATCH
|
|
#undef JSON_TRY
|
|
#undef JSON_HAS_CPP_11
|
|
#undef JSON_HAS_CPP_14
|
|
#undef JSON_HAS_CPP_17
|
|
#undef JSON_HAS_CPP_20
|
|
#undef JSON_HAS_CPP_23
|
|
#undef JSON_HAS_CPP_26
|
|
#undef JSON_HAS_FILESYSTEM
|
|
#undef JSON_HAS_EXPERIMENTAL_FILESYSTEM
|
|
#undef JSON_HAS_THREE_WAY_COMPARISON
|
|
#undef JSON_HAS_RANGES
|
|
#undef JSON_HAS_RANGE_VIEW_CONVERSION
|
|
#undef JSON_HAS_STD_FORMAT
|
|
#undef JSON_HAS_STATIC_RTTI
|
|
#undef JSON_USE_LEGACY_DISCARDED_VALUE_COMPARISON
|
|
#undef JSON_BRACE_INIT_COPY_SEMANTICS
|
|
#undef JSON_PRECISE_STREAM_POSITION
|
|
#undef JSON_STRICT_NUL_HANDLING
|
|
#undef JSON_STRICT_BINARY_UTF8
|
|
#undef JSON_DELETE_DEPRECATED_FUNCTIONS
|
|
#endif
|
|
|
|
#include <nlohmann/thirdparty/hedley/hedley_undef.hpp>
|