mirror of
https://github.com/nlohmann/json.git
synced 2025-08-06 07:02:42 +03:00
include io only if JSON_NO_IO is not set for #2728
This commit is contained in:
@@ -2,9 +2,7 @@
|
|||||||
|
|
||||||
#include <array> // array
|
#include <array> // array
|
||||||
#include <cstddef> // size_t
|
#include <cstddef> // size_t
|
||||||
#include <cstdio> //FILE *
|
|
||||||
#include <cstring> // strlen
|
#include <cstring> // strlen
|
||||||
#include <istream> // istream
|
|
||||||
#include <iterator> // begin, end, iterator_traits, random_access_iterator_tag, distance, next
|
#include <iterator> // begin, end, iterator_traits, random_access_iterator_tag, distance, next
|
||||||
#include <memory> // shared_ptr, make_shared, addressof
|
#include <memory> // shared_ptr, make_shared, addressof
|
||||||
#include <numeric> // accumulate
|
#include <numeric> // accumulate
|
||||||
@@ -12,6 +10,11 @@
|
|||||||
#include <type_traits> // enable_if, is_base_of, is_pointer, is_integral, remove_pointer
|
#include <type_traits> // enable_if, is_base_of, is_pointer, is_integral, remove_pointer
|
||||||
#include <utility> // pair, declval
|
#include <utility> // pair, declval
|
||||||
|
|
||||||
|
#ifndef JSON_NO_IO
|
||||||
|
#include <cstdio> //FILE *
|
||||||
|
#include <istream> // istream
|
||||||
|
#endif // JSON_NO_IO
|
||||||
|
|
||||||
#include <nlohmann/detail/iterators/iterator_traits.hpp>
|
#include <nlohmann/detail/iterators/iterator_traits.hpp>
|
||||||
#include <nlohmann/detail/macro_scope.hpp>
|
#include <nlohmann/detail/macro_scope.hpp>
|
||||||
|
|
||||||
|
@@ -2,12 +2,16 @@
|
|||||||
|
|
||||||
#include <algorithm> // copy
|
#include <algorithm> // copy
|
||||||
#include <cstddef> // size_t
|
#include <cstddef> // size_t
|
||||||
#include <ios> // streamsize
|
|
||||||
#include <iterator> // back_inserter
|
#include <iterator> // back_inserter
|
||||||
#include <memory> // shared_ptr, make_shared
|
#include <memory> // shared_ptr, make_shared
|
||||||
#include <ostream> // basic_ostream
|
|
||||||
#include <string> // basic_string
|
#include <string> // basic_string
|
||||||
#include <vector> // vector
|
#include <vector> // vector
|
||||||
|
|
||||||
|
#ifndef JSON_NO_IO
|
||||||
|
#include <ios> // streamsize
|
||||||
|
#include <ostream> // basic_ostream
|
||||||
|
#endif // JSON_NO_IO
|
||||||
|
|
||||||
#include <nlohmann/detail/macro_scope.hpp>
|
#include <nlohmann/detail/macro_scope.hpp>
|
||||||
|
|
||||||
namespace nlohmann
|
namespace nlohmann
|
||||||
|
@@ -38,7 +38,9 @@ SOFTWARE.
|
|||||||
#include <cstddef> // nullptr_t, ptrdiff_t, size_t
|
#include <cstddef> // nullptr_t, ptrdiff_t, size_t
|
||||||
#include <functional> // hash, less
|
#include <functional> // hash, less
|
||||||
#include <initializer_list> // initializer_list
|
#include <initializer_list> // initializer_list
|
||||||
#include <iosfwd> // istream, ostream
|
#ifndef JSON_NO_IO
|
||||||
|
#include <iosfwd> // istream, ostream
|
||||||
|
#endif // JSON_NO_IO
|
||||||
#include <iterator> // random_access_iterator_tag
|
#include <iterator> // random_access_iterator_tag
|
||||||
#include <memory> // unique_ptr
|
#include <memory> // unique_ptr
|
||||||
#include <numeric> // accumulate
|
#include <numeric> // accumulate
|
||||||
@@ -6882,7 +6884,7 @@ class basic_json
|
|||||||
parser(detail::input_adapter(i)).parse(false, j);
|
parser(detail::input_adapter(i)).parse(false, j);
|
||||||
return i;
|
return i;
|
||||||
}
|
}
|
||||||
#endif // JSON_NO_IO
|
#endif // JSON_NO_IO
|
||||||
/// @}
|
/// @}
|
||||||
|
|
||||||
///////////////////////////
|
///////////////////////////
|
||||||
|
Reference in New Issue
Block a user