#json
5 posts tagged #json.
simdjson 5.0 reads a struct from JSON keys in any order
simdjson 5.0.0 (28 Sep 2026) lists static reflection as an officially supported feature. A struct with a string, an int, a bool, a nested struct and a vector read from JSON with shuffled keys on GCC 16.2 and simdjson 5.0.2, and an integer of exactly 2^64 is now a big integer. The 1.8x speedup in the release notes covers parsing escaped Unicode.
Deserialization and std::expected: completing the round-trip
Parse JSON into a typed C++ struct with precise per-field error reporting via std::expected. Reflection + template for + annotations — the same machinery, just running the other way.
A 40-line JSON serializer with reflection
Corrected on 6 October 2026: there is no reflect_json library, and the speed figures in the first version were not measured with a method I can show. The post walks a struct and emits JSON in about fifty lines, with no macros and no external codegen; the corrected measurement is in the Runtime cost section.
simdjson meets reflection: sb << my_struct at 6.8 GB/s
simdjson now ships a C++26 reflection backend: define SIMDJSON_STATIC_REFLECTION, and sb << my_struct serializes any aggregate at SIMD speed. The CITM Catalog benchmark hits 6.8 GB/s. Combined with P3394 annotations for rename/skip, this is the production JSON path the reflection series has been building toward.
Glaze v7.2 vs your hand-rolled JSON: a 30-line benchmark
Glaze v7.2 ships a P2996 backend that retires __PRETTY_FUNCTION__, lifts the 128-member cap, and serializes private members. Here is when you still write your own thirty lines -- and when one call wins.