github nlohmann/json v3.11.2
JSON for Modern C++ version 3.11.2

latest release: v3.11.3
21 months ago

Release date: 2022-08-12
SHA-256: 665fa14b8af3837966949e8eb0052d583e2ac105d3438baba9951785512cf921 (json.hpp), e5c7a9f49a16814be27e4ed0ee900ecd0092bfb7dbfca65b5a421b774dccaaed (include.zip), 8c4b26bf4b422252e13f332bc5e388ec0ab5c3443d24399acb675e68278d341f (json.tar.xz)

Summary

This release fixes some bugs found in the 3.11.1 release. Furthermore, the of the library has been re-structured.

All changes are backward-compatible.

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

🐛 Bug Fixes

  • Fix the value function which was broken for strings, size types, and nullptr in release 3.11.0. #3652 #3655 #3663
  • Fix the json_fwd.hpp header to be self-contained and add it to the single-header release. #3656 #3679 #3687
  • Fix regression that broke using json_pointer as key in associative containers. #3680 #3685
  • Add missing constraint to deprecated JSON Pointer overloads of contains and at. #3658 #3681
  • Fix comparison between json_pointer and strings with == and !=. These comparisons worked in 3.10.5, but were broken in 3.11.0 and 3.11.1. #3654 #3664
  • Fix to_json conversion of std::vector<bool>::reference and std::vector<bool>::const_reference for STLs where these are the same as basic_json::boolean_t& and basic_json::boolean_t, respectively. #3677 #3678

⚡ Improvements

🔨 Further Changes

Documentation

Community

  • Add a badge for the Discord chat to the README file. The goal of that additional communication channel beyond the existing ones is to quickly coordinate between the contributors. #3651
  • Complete contributor list. #3662 #3670

CI

  • Remove the macos-10.15 image from the CI as it is removed by GitHub Actions. #3612 #3615 #3626
  • Remove hardcoded paths in Ubuntu workflow. #3626
  • Only trigger AppVeyor builds if relevant files have been changed. #3626
  • Fix CodeQL warning. #3626
  • Harmonize naming of GitHub Actions jobs. #3661
  • Add labeler action to automatically add PR labels based on the changed files. #3671 #3674 #3675
  • Lint API documentation in the CI. #3672
  • Add local LGTM configuration and suppress warnings on third-party scripts. #3643

🔥 Deprecated functions

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

  • The function iterator_wrapper is 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.
  • 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 implicit conversion from JSON Pointers to string (json_pointer::operator string_t) is deprecated. Use json_pointer::to_string instead.

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

Don't miss a new json release

NewReleases is sending notifications on new releases.