| 1178 | |
| 1179 | template<typename BasicJsonType, typename CompatibleArrayType> |
| 1180 | void from_json_array_impl(const BasicJsonType& j, CompatibleArrayType& arr, priority_tag<0> /*unused*/) |
| 1181 | { |
| 1182 | using std::end; |
| 1183 | |
| 1184 | std::transform(j.begin(), j.end(), |
| 1185 | std::inserter(arr, end(arr)), [](const BasicJsonType & i) |
| 1186 | { |
| 1187 | // get<BasicJsonType>() returns *this, this won't call a from_json |
| 1188 | // method when value_type is BasicJsonType |
| 1189 | return i.template get<typename CompatibleArrayType::value_type>(); |
| 1190 | }); |
| 1191 | } |
| 1192 | |
| 1193 | template<typename BasicJsonType, typename CompatibleArrayType> |
| 1194 | auto from_json_array_impl(const BasicJsonType& j, CompatibleArrayType& arr, priority_tag<1> /*unused*/) |