From 18e7c013595fbf6574a32c5ae5fa9406a577eab5 Mon Sep 17 00:00:00 2001 From: Peter Dimov Date: Mon, 9 Sep 2024 20:23:58 +0300 Subject: [PATCH] Update JSON examples for JSON 1.81+ --- example/from_json.cpp | 5 +++++ example/to_json.cpp | 5 +++++ 2 files changed, 10 insertions(+) diff --git a/example/from_json.cpp b/example/from_json.cpp index 74d651f..2c425d3 100644 --- a/example/from_json.cpp +++ b/example/from_json.cpp @@ -5,11 +5,14 @@ #include #include #include +#include #include namespace app { +#if BOOST_VERSION < 108100 + template void extract( boost::json::object const & obj, char const * name, T & value ) { value = boost::json::value_to( obj.at( name ) ); @@ -36,6 +39,8 @@ template #include #include +#include #include #include #include @@ -12,6 +13,8 @@ namespace app { +#if BOOST_VERSION < 108100 + template, @@ -29,6 +32,8 @@ template