Logo
Explore Help
Register Sign In
starred/json
Watch 1
Star 0
Fork 0
mirror of https://github.com/nlohmann/json.git synced 2026-09-24 06:10:22 +01:00
Code Issues Packages Projects Releases 10 Wiki Activity

10 Releases 57 Tags

RSS Feed
  • v3.10.5 4f8fba1406
    Compare

    JSON for Modern C++ version 3.10.5 Stable

    feyisay07 released this 2022-01-03 05:40:13 +00:00 | 781 commits to develop since this release

    📅 Originally published on GitHub: Mon, 03 Jan 2022 05:41:00 GMT
    🏷️ Git tag created: Mon, 03 Jan 2022 05:40:13 GMT

    Release date: 2022-01-03
    SHA-256: e832d339d9e0c042e7dff807754769d778cf5d6ae9730ce21eed56de99cb5e86 (json.hpp), b94997df68856753b72f0d7a3703b7d484d4745c567f3584ef97c96c25a5798e (include.zip)

    Summary

    The previous version 3.10.4 introduced support to convert std::filesystem objects to JSON and vice versa. Unfortunately, we made the assumption that any compiler supporting C++17 would also have proper filesystem support. This was a mistake. This release introduces preprocessor checks (and means to override them) to make sure that the conversion support is only compiled if the compiler is detected to support it.

    All changes are backward-compatible.

    💰 Note you can support this project via GitHub sponsors or PayPal.

    🐛 Bug fixes

    • Make sure C++17 filesystem conversions are only used if the compiler supports it. Furthermore, add defines JSON_HAS_FILESYSTEM and JSON_HAS_EXPERIMENTAL_FILESYSTEM which can be set to 0 to avoid using filesystem support altogether.std::filesystem. #3090 #3097 #3101 #3156 #3203
    • Fix a compilation error with Nvidia CUDA Compiler (NVCC). #3013 #3234

    Warnings

    • Fix a warning for shadowed variables. #3188 #3193
    • Fix a warning on a pointless comparison. #3227 #2712 #2676 #1390 #755

    ⚡ Improvements

    • Add a parameter to the update function to recursively merge objects with common keys. #3006 #3069
    • Extend std::hash and std::swap to work on any nlohmann::basic_json specializations rather than just nlohmann::json. #3121

    🔨 Further Changes

    Tests and CI

    • Update CI to use Clang 14, GCC 6, and Clang-Tidy 14. #3088
    • Update cpplint. #3225
    • Add build step for the Nvidia CUDA Compiler (NVCC). #3227
    • Remove Travis CI. #3087 #3233
    • Compile and execute the test suite with C++17. #3101

    Documentation

    • The mkdocs-based documentation in doc/mkdocs has been totally overworked. It now has a unified structure, more examples, and contains all information from the previous Doxygen-based documentation. The single source of truth is now the documentation on https://json.nlohmann.me and in particular the API Documentation. #3071
    • Removed Wandbox online examples. #3071
    • Fix typos, links, and parameter names in the documentation. #3102 #3125 #3140 #3145 #3148
    • Add more examples. #3071 #3100

    🔥 Deprecated functions

    Passing iterator pairs or pointer/length pairs to parsing functions (basic_json::parse, basic_json::accept, basic_json::sax_parse, basic_json::from_cbor, basic_json::from_msgpack, basic_json::from_ubjson, basic_json::from_bson) via initializer lists is deprecated. Instead, pass two iterators; for instance, call basic_json::from_cbor(ptr, ptr+len) instead of basic_json::from_cbor({ptr, len}).

    The following functions have been deprecated in earlier versions and will be removed in the next major version (i.e., 4.0.0):

    • Function iterator_wrapper are deprecated. Please use the member function items() instead.
    • Functions friend std::istream& operator<<(basic_json&, std::istream&) and friend std::ostream& operator>>(const basic_json&, std::ostream&) are deprecated. Please use friend std::istream& operator>>(std::istream&, basic_json&) and friend operator<<(std::ostream&, const basic_json&) instead.

    All deprecations are annotated with HEDLEY_DEPRECATED_FOR to report which function to use instead.

    Downloads
    • include.zip
      255 KiB
      2026-07-03 14:26:35 +01:00
    • include.zip.asc
      833 B
      2026-07-03 14:26:36 +01:00
    • json.hpp
      785 KiB
      2026-07-03 14:26:36 +01:00
    • json.hpp.asc
      833 B
      2026-07-03 14:26:37 +01:00
    • json.tar.xz
      98 KiB
      2026-07-03 14:26:37 +01:00
    • Source Code (ZIP)
    • Source Code (TAR.GZ)
Powered by Gitea Version: 1.27.3 Page: 20ms Template: 1ms
Auto
English
Bahasa Indonesia Deutsch English Español Français Gaeilge Italiano Latviešu Magyar nyelv Nederlands Polski Português de Portugal Português do Brasil Suomi Svenska Türkçe Čeština Ελληνικά Български Русский Українська فارسی മലയാളം 日本語 简体中文 繁體中文(台灣) 繁體中文(香港) 한국어
Licenses API