Range-v3
Range algorithms, views, and actions for the Standard Library
optional.hpp File Reference

Classes

struct  ranges::bad_optional_access
 
struct  ranges::nullopt_t
 
struct  ranges::nullopt_t::tag
 
struct  ranges::optional< T >
 

Concepts

concept  ranges::optional_should_convert
 The optional_should_convert concept.
 
concept  ranges::optional_should_convert_assign
 The optional_should_convert_assign concept.
 

Functions

template<typename T , typename... Args>
constexpr auto ranges::make_optional (Args &&... args) noexcept(noexcept(decltype(optional< T >{in_place, static_cast< Args && >(args)...})(optional< T >{in_place, static_cast< Args && >(args)...}))) -> decltype(optional< T >{in_place, static_cast< Args && >(args)...})
 
template<typename T , typename U , typename... Args>
constexpr auto ranges::make_optional (std::initializer_list< U > il, Args &&... args) noexcept(noexcept(decltype(optional< T >{in_place, il, static_cast< Args && >(args)...})(optional< T >{in_place, il, static_cast< Args && >(args)...}))) -> decltype(optional< T >{in_place, il, static_cast< Args && >(args)...})
 
template<typename T >
constexpr auto ranges::make_optional (T &&t) noexcept(noexcept(decltype(optional< detail::decay_t< T > >{static_cast< T && >(t)})(optional< detail::decay_t< T > >{static_cast< T && >(t)}))) -> decltype(optional< detail::decay_t< T > >{static_cast< T && >(t)})