|
1 | | -/* auto-generated on 2025-09-29 20:34:35 -0700. version 4.0.7 Do not edit! */ |
| 1 | +/* auto-generated on 2025-10-27 16:52:41 -0400. version 4.1.0 Do not edit! */ |
2 | 2 | /* including simdjson.cpp: */ |
3 | 3 | /* begin file simdjson.cpp */ |
4 | 4 | #define SIMDJSON_SRC_SIMDJSON_CPP |
@@ -3030,6 +3030,25 @@ concept container_but_not_string = |
3030 | 3030 | std::ranges::input_range<T> && !string_like<T> && !concepts::string_view_keyed_map<T>; |
3031 | 3031 |
|
3032 | 3032 |
|
| 3033 | + |
| 3034 | +// Concept: Indexable container that is not a string or associative container |
| 3035 | +// Accepts: std::vector, std::array, std::deque (have operator[], value_type, not string_like) |
| 3036 | +// Rejects: std::string (string_like), std::list (no operator[]), std::map (has key_type) |
| 3037 | +template<typename Container> |
| 3038 | +concept indexable_container = requires { |
| 3039 | + typename Container::value_type; |
| 3040 | + requires !concepts::string_like<Container>; |
| 3041 | + requires !requires { typename Container::key_type; }; // Reject maps/sets |
| 3042 | + requires requires(Container& c, std::size_t i) { |
| 3043 | + { c[i] } -> std::convertible_to<typename Container::value_type>; |
| 3044 | + }; |
| 3045 | +}; |
| 3046 | + |
| 3047 | + |
| 3048 | +// Variable template to use with std::meta::substitute |
| 3049 | +template<typename Container> |
| 3050 | +constexpr bool indexable_container_v = indexable_container<Container>; |
| 3051 | + |
3033 | 3052 | } // namespace concepts |
3034 | 3053 |
|
3035 | 3054 |
|
@@ -5047,7 +5066,8 @@ namespace internal { |
5047 | 5066 | { INCOMPLETE_ARRAY_OR_OBJECT, "INCOMPLETE_ARRAY_OR_OBJECT: JSON document ended early in the middle of an object or array. This is a fatal and unrecoverable error." }, |
5048 | 5067 | { SCALAR_DOCUMENT_AS_VALUE, "SCALAR_DOCUMENT_AS_VALUE: A JSON document made of a scalar (number, Boolean, null or string) is treated as a value. Use get_bool(), get_double(), etc. on the document instead. "}, |
5049 | 5068 | { OUT_OF_BOUNDS, "OUT_OF_BOUNDS: Attempt to access location outside of document."}, |
5050 | | - { TRAILING_CONTENT, "TRAILING_CONTENT: Unexpected trailing content in the JSON input."} |
| 5069 | + { TRAILING_CONTENT, "TRAILING_CONTENT: Unexpected trailing content in the JSON input."}, |
| 5070 | + { OUT_OF_CAPACITY, "OUT_OF_CAPACITY: The capacity was exceeded, we cannot allocate enough memory."} |
5051 | 5071 | }; // error_messages[] |
5052 | 5072 |
|
5053 | 5073 | } // namespace internal |
|
0 commit comments