12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758 |
- #ifndef BOOST_JSON_IMPL_VALUE_REF_HPP
- #define BOOST_JSON_IMPL_VALUE_REF_HPP
- namespace boost {
- namespace json {
- template<class T>
- value
- value_ref::
- from_builtin(
- void const* p,
- storage_ptr sp) noexcept
- {
- return value(
- *reinterpret_cast<
- T const*>(p),
- std::move(sp));
- }
- template<class T>
- value
- value_ref::
- from_const(
- void const* p,
- storage_ptr sp)
- {
- return value(
- *reinterpret_cast<
- T const*>(p),
- std::move(sp));
- }
- template<class T>
- value
- value_ref::
- from_rvalue(
- void* p,
- storage_ptr sp)
- {
- return value(
- std::move(
- *reinterpret_cast<T*>(p)),
- std::move(sp));
- }
- }
- }
- #endif
|