add detail/conversions/from_json.hpp

parent 7056b375
......@@ -7,7 +7,9 @@ SRCS = ${SRCDIR}/json.hpp \
${SRCDIR}/detail/macro_unscope.hpp \
${SRCDIR}/detail/meta.hpp \
${SRCDIR}/detail/exceptions.hpp \
${SRCDIR}/detail/value_t.hpp
${SRCDIR}/detail/value_t.hpp \
${SRCDIR}/detail/conversions/from_json.hpp
......
......@@ -220,6 +220,16 @@ struct has_to_json
static constexpr bool value = std::is_integral<decltype(detect(
std::declval<typename BasicJsonType::template json_serializer<T, void>>()))>::value;
};
// taken from ranges-v3
template<typename T>
struct static_const
{
static constexpr T value{};
};
template<typename T>
constexpr T static_const<T>::value;
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment