mirror of
https://github.com/nlohmann/json.git
synced 2026-11-06 12:39:22 +00:00
meta: fix is_compatible/constructible traits (#3020)
The previous version relied on the existence of an 'iterator' type. As mentioned in comments, this is not the proper way to do it and causes issues with certain types (e.g. views from range-v3). Add a 'is_range' trait that properly detects the return type of 'begin'/'end', and use it in instead.
This commit is contained in:
1 parent
62f2997b79
commit
80df5e8de6
7 files changed
+321
-132
No files matched your search
@@ -19,5 +19,6 @@
|
||||
#undef NLOHMANN_BASIC_JSON_TPL_DECLARATION
|
||||
#undef NLOHMANN_BASIC_JSON_TPL
|
||||
#undef JSON_EXPLICIT
|
||||
#undef NLOHMANN_CAN_CALL_STD_FUNC_IMPL
|
||||
|
||||
#include <nlohmann/thirdparty/hedley/hedley_undef.hpp>
|
||||
Reference in new issue
Block a user