2 ms·
Code in jart's version is refreshingly clean and easy to read compared the nlohmann's version. As an aside, I wonder: what are the ThomPike* set of macros actu
by ur-whale 2y ago
Code in jart's version is refreshingly clean and easy to read compared the nlohmann's version.
As an aside, I wonder: what are the ThomPike* set of macros actually doing in jart's implem ?
Also, a speed comparison of this vs the other one would be very welcome: conformance and simplicity are certainly important criteria when picking a JSON parser, but speed is rather crucial.
- jart 2y agoThompson Pike encoding. It predates the UTF-8 standard and was invented on a napkin in a New Jersey diner. It allows the full spectrum of 32-bit numbers to be encoded, rather than restricting characters to only those also present in UTF-16. The json.cpp library enforces UTF-8 restrictions on parsing, because we have no choice. But you're allowed to serialize anything you want, thanks to the ThomPike macros.