On Mon, Jun 15, 2020 at 4:18 AM Andrzej Krzemienski <akrze...@gmail.com> wrote: > can they use their string in Boost.JSON?
No. The design of the library explicitly avoids allowing customizability. > It should be possible to parametrize Boost.JSON with the string type. This has been explored in other libraries, and I don't like the result. Here is nlohmann JSON's value type: template< template<typename, typename, typename...> class ObjectType, template<typename, typename...> class ArrayType, class StringType, class BooleanType, class NumberIntegerType, class NumberUnsignedType, class NumberFloatType, template<typename> class AllocatorType, template<typename, typename = void> class JSONSerializer > class basic_json { private: .... friend ::nlohmann::detail::parser<basic_json>; friend ::nlohmann::detail::serializer<basic_json>; ... <http://vinniefalco.github.io/doc/json/json/comparison.html#json.comparison.comparison_to_nlohmann_json> Thanks, but no thanks. As I said the library achieves its performance partly due to the layout of the different types used in the discriminated union, of which string is one. Users aren't asking for "using their own string type in the JSON DOM." What they want is the speed of RapidJSON, options for skipping comments, allowing trailing commas, and flexible parsing, and the interface quality of a Boost library. Thanks _______________________________________________ Boost-users mailing list Boost-users@lists.boost.org https://lists.boost.org/mailman/listinfo.cgi/boost-users