Merge pull request #1134 from Daniel599/feature/items_iterator
fixed compile error for #1045
This commit is contained in:
		
						commit
						86a96b059d
					
				
					 4 changed files with 82 additions and 3 deletions
				
			
		| 
						 | 
				
			
			@ -294,6 +294,16 @@ void to_json(BasicJsonType& j, const std::pair<Args...>& p)
 | 
			
		|||
    j = {p.first, p.second};
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
template<typename IteratorType> class iteration_proxy; // TODO: Forward decl needed, maybe move somewhere else
 | 
			
		||||
template<typename BasicJsonType, typename T,
 | 
			
		||||
         enable_if_t<std::is_same<T, typename iteration_proxy<typename BasicJsonType::iterator>::iteration_proxy_internal>::value, int> = 0>
 | 
			
		||||
void to_json(BasicJsonType& j, T b) noexcept
 | 
			
		||||
{
 | 
			
		||||
    typename BasicJsonType::object_t tmp_obj;
 | 
			
		||||
    tmp_obj[b.key()] = b.value(); // TODO: maybe there is a better way?
 | 
			
		||||
    external_constructor<value_t::object>::construct(j, std::move(tmp_obj));
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
template<typename BasicJsonType, typename Tuple, std::size_t... Idx>
 | 
			
		||||
void to_json_tuple_impl(BasicJsonType& j, const Tuple& t, index_sequence<Idx...>)
 | 
			
		||||
{
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue