/compile-time-json

Parse JSON at compile time, create a structure to hold that JSON and pass that JSON as template parameter if you wish XD

Primary LanguageC++GNU General Public License v3.0GPL-3.0

compile-time-json

This library allows you to create C++ structures with standard layout that hold JSON object from compile time JSON string while allowing modification of values and reassignment at runtime with constant time access. The JSON objects can also be passed as template parameters as the objects are literal types. See the example for further details on the interfaces and possible use cases.

How to Build

This library requires a compiler with C++20 support. You can compile the example using the Bazel build system with the following command:

bazel run //example:example