From 307c053b9b250abc6e6d478a4336fd98592ae173 Mon Sep 17 00:00:00 2001 From: Florian Albrechtskirchinger Date: Tue, 30 Aug 2022 20:55:47 +0200 Subject: [PATCH] Add missing include (#3719) --- include/nlohmann/detail/exceptions.hpp | 3 +++ include/nlohmann/json.hpp | 1 - single_include/nlohmann/json.hpp | 4 +++- 3 files changed, 6 insertions(+), 2 deletions(-) diff --git a/include/nlohmann/detail/exceptions.hpp b/include/nlohmann/detail/exceptions.hpp index 96d7e0104..9f82d7f06 100644 --- a/include/nlohmann/detail/exceptions.hpp +++ b/include/nlohmann/detail/exceptions.hpp @@ -10,6 +10,9 @@ #include // nullptr_t #include // exception +#if JSON_DIAGNOSTICS + #include // accumulate +#endif #include // runtime_error #include // to_string #include // vector diff --git a/include/nlohmann/json.hpp b/include/nlohmann/json.hpp index c28726370..8a3cfdbf9 100644 --- a/include/nlohmann/json.hpp +++ b/include/nlohmann/json.hpp @@ -27,7 +27,6 @@ #endif // JSON_NO_IO #include // random_access_iterator_tag #include // unique_ptr -#include // accumulate #include // string, stoi, to_string #include // declval, forward, move, pair, swap #include // vector diff --git a/single_include/nlohmann/json.hpp b/single_include/nlohmann/json.hpp index 83705f9f8..03bdb113e 100644 --- a/single_include/nlohmann/json.hpp +++ b/single_include/nlohmann/json.hpp @@ -27,7 +27,6 @@ #endif // JSON_NO_IO #include // random_access_iterator_tag #include // unique_ptr -#include // accumulate #include // string, stoi, to_string #include // declval, forward, move, pair, swap #include // vector @@ -183,6 +182,9 @@ #include // nullptr_t #include // exception +#if JSON_DIAGNOSTICS + #include // accumulate +#endif #include // runtime_error #include // to_string #include // vector