v2.9.0
Breaking change: Removed pure reflection support for C style arrays
This does not break C style array registration in glz::meta
or the local glaze
metadata. It should also produce compile time errors that are obvious.
C++ allows flattening of brace initializers for C style arrays, which means that they break how we count fields in a struct. The work around was to count the number of initializer lists that we can use to construct the type. However, this approach was not consistent across MSVC, Clang, and GCC, and it restricted commonly used types with custom constructors (like std::filesystem::path
and std::chrono::seconds
).
After lots of experimenting, reading the C++ specification and papers, and submitting compiler bugs, it's become clear that dropping this support will make Glaze more stable for the future until we get compile time reflection into the language.
Tip
Reflection still works with std::array
, so the C style arrays can be converted to std::array
and pure reflection in Glaze will work as before.
- by @stephenberry in #1097
Improvements
- Internal thread pool improvements and fixed
std::promise<void>
handling in #1085 - Using buffer pool for asio client in #1095
- Fix MSVC warnings in #1099
Full Changelog: v2.8.4...v2.9.0