| 13962 | detail::conjunction<std::is_default_constructible<ValueType>, detail::negation<std::is_pointer<T>>>::value, |
| 13963 | int> = 0> |
| 13964 | T get_value() const noexcept( |
| 13965 | noexcept(std::declval<const basic_node&>().template get_value_impl<ValueType>(std::declval<ValueType&>()))) { |
| 13966 | // emit a compile error if T is either a reference, pointer or C-style array type. |
| 13967 | static_assert( |
| 13968 | !std::is_reference<T>::value, |
| 13969 | "get_value() cannot be called with reference types. " |
| 13970 | "You might want to call one of as_seq(), as_map(), as_bool(), as_int(), as_float() or as_str()."); |
| 13971 | static_assert( |
| 13972 | !std::is_array<T>::value, |
| 13973 | "get_value() cannot be called with C-style array types. You might want to call get_value_inplace()."); |
| 13974 | |
| 13975 | auto ret = ValueType(); |
| 13976 | resolve_reference().get_value_impl(ret); |
| 13977 | return ret; |
| 13978 | } |
| 13979 | |
| 13980 | /// @brief Get the node value object converted into a given type. The conversion result is filled into `value_ref`. |
| 13981 | /// @tparam T A compatible value type. |
nothing calls this directly
no test coverage detected