github stephenberry/glaze v1.3.0
1.3.0

latest releases: v9.0.0, v8.4.0, v8.3.0...
3 years ago

BREAKING v1.3.0 CHANGE: std::pair is now handled as a JSON object ({"first":second}}. If you require a JSON array of two items, use std::array or std::tuple.

Removed MSVC 2019 support (the compiler has too many limitations for ranges and compile time logic)

  • Added numeric enum support (default behavior)
  • std::string reading with CSV format
  • Added separate concepts for readable_map_t and writable_map_t (thanks @justend29)
  • Views and ranges of std::pair can now be serialized as objects: (thanks @justend29)
auto num_view =
std::views::iota(-2, 3) | std::views::transform([](const auto i) { return std::pair(i, i * i); });
expect(glz::write_json(num_view) == glz::sv{R"({"-2":4,"-1":1,"0":0,"1":1,"2":4})"});
  • Added glz::invoke and glz::invoke_update, which allow invoking functions when reading JSON input
  • Added GLZ_QUOTED_X helper macro (thanks @pwqbot)

Don't miss a new glaze release

NewReleases is sending notifications on new releases.