17 #ifndef BOOST_OPTIONAL_OPTIONAL_FLC_19NOV2002_HPP 18 #define BOOST_OPTIONAL_OPTIONAL_FLC_19NOV2002_HPP 60 #if (defined BOOST_NO_CXX11_RVALUE_REFERENCES) || (defined BOOST_OPTIONAL_CONFIG_NO_RVALUE_REFERENCES) 61 #define BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES 64 #if BOOST_WORKAROUND(BOOST_INTEL_CXX_VERSION,<=700) 69 #define BOOST_OPTIONAL_NO_INPLACE_FACTORY_SUPPORT 72 #if BOOST_WORKAROUND(__BORLANDC__, <= 0x551) 74 #define BOOST_OPTIONAL_NO_INPLACE_FACTORY_SUPPORT 77 #if !defined(BOOST_OPTIONAL_NO_INPLACE_FACTORY_SUPPORT) \ 78 && BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x581) ) 85 #define BOOST_OPTIONAL_WEAK_OVERLOAD_RESOLUTION 88 #if defined(__GNUC__) && !defined(__INTEL_COMPILER) 93 #define BOOST_OPTIONAL_DETAIL_USE_ATTRIBUTE_MAY_ALIAS 102 template <
class T,
class Factory>
105 factory.BOOST_NESTED_TEMPLATE apply<T>(
address);
112 class in_place_factory_base ;
113 class typed_in_place_factory_base ;
116 template<
class T>
void swap ( optional<T>&
x, optional<T>&
y );
118 namespace optional_detail {
129 #if defined(BOOST_OPTIONAL_DETAIL_USE_ATTRIBUTE_MAY_ALIAS) 130 __attribute__((__may_alias__))
141 #if defined(BOOST_OPTIONAL_DETAIL_USE_ATTRIBUTE_MAY_ALIAS) 142 void const*
address()
const {
return &dummy_; }
143 void *
address() {
return &dummy_; }
145 void const*
address()
const {
return dummy_.data; }
155 #ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES 158 #ifdef BOOST_MOVE_OLD_RVALUE_REF_BINDING_RULES 161 static T&&
move(
T&&
r) {
return r; }
178 #ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES 181 static reference_type
move(reference_type
r) {
return r; }
188 template <
class To,
class From>
191 #ifndef BOOST_OPTIONAL_CONFIG_ALLOW_BINDING_TO_RVALUES 194 "binding rvalue references to optional lvalue references is disallowed");
206 #if !BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564)) 233 #ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES 245 m_initialized(false) {}
251 m_initialized(false) {}
262 #ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES 293 #ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES 300 if ( rhs.is_initialized() )
305 #ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES 307 template<
class Expr,
class PtrExpr>
312 construct(boost::forward<Expr>(expr),tag);
336 if (is_initialized())
339 assign_value(rhs.
get_impl(), is_reference_predicate() );
349 #ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES 353 if (is_initialized())
355 if ( rhs.is_initialized() )
356 assign_value(
boost::move(rhs.get_impl()), is_reference_predicate() );
361 if ( rhs.is_initialized() )
371 if (is_initialized())
374 #ifndef BOOST_OPTIONAL_CONFIG_RESTORE_ASSIGNMENT_OF_NONCONVERTIBLE_TYPES
375 assign_value(rhs.
get(), is_reference_predicate() );
377 assign_value(static_cast<value_type>(rhs.
get()), is_reference_predicate() );
385 #ifndef BOOST_OPTIONAL_CONFIG_RESTORE_ASSIGNMENT_OF_NONCONVERTIBLE_TYPES
393 #ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES 399 if (is_initialized())
401 if ( rhs.is_initialized() )
402 assign_value(static_cast<ref_type>(rhs.get()), is_reference_predicate() );
407 if ( rhs.is_initialized() )
408 construct(static_cast<ref_type>(rhs.get()));
416 if (is_initialized())
417 assign_value(val, is_reference_predicate() );
421 #ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES 425 if (is_initialized())
426 assign_value(
boost::move(val), is_reference_predicate() );
435 #ifndef BOOST_OPTIONAL_NO_INPLACE_FACTORY_SUPPORT 437 #ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES 438 template<
class Expr,
class ExprPtr>
441 if (is_initialized())
442 assign_expr_to_initialized(boost::forward<Expr>(expr),tag);
443 else construct(boost::forward<Expr>(expr),tag);
447 void assign_expr (
Expr const& expr,
Expr const* tag )
449 if (is_initialized())
450 assign_expr_to_initialized(expr,tag);
469 pointer_const_type
get_ptr()
const {
return m_initialized ? get_ptr_impl() : 0 ; }
470 pointer_type
get_ptr() {
return m_initialized ? get_ptr_impl() : 0 ; }
478 ::new (m_storage.address()) internal_type(val) ;
479 m_initialized = true ;
482 #ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES 485 ::new (m_storage.address()) internal_type(
types::move(val) ) ;
486 m_initialized = true ;
491 #if (!defined BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES) && (!defined BOOST_NO_CXX11_VARIADIC_TEMPLATES) 494 template<
class... Args>
498 ::new (m_storage.address()) internal_type( boost::forward<Args>(
args)... );
499 m_initialized = true ;
501 #elif (!defined BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES) 503 void emplace_assign ( Arg&&
arg )
506 ::new (m_storage.address()) internal_type( boost::forward<Arg>(
arg) );
507 m_initialized = true ;
511 void emplace_assign (
const Arg&
arg )
514 ::new (m_storage.address()) internal_type( arg );
515 m_initialized = true ;
519 void emplace_assign ( Arg& arg )
522 ::new (m_storage.address()) internal_type( arg );
523 m_initialized = true ;
527 #ifndef BOOST_OPTIONAL_NO_INPLACE_FACTORY_SUPPORT 529 #ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES 535 boost_optional_detail::construct<value_type>(
factory, m_storage.address());
536 m_initialized = true ;
544 factory.apply(m_storage.address()) ;
545 m_initialized = true ;
569 boost_optional_detail::construct<value_type>(
factory, m_storage.address());
570 m_initialized = true ;
575 void construct (
Expr const& factory, typed_in_place_factory_base
const* )
578 factory.apply(m_storage.address()) ;
579 m_initialized = true ;
591 void assign_expr_to_initialized (
Expr const& factory, typed_in_place_factory_base
const* tag )
600 #ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES 608 new (m_storage.address()) internal_type(boost::forward<Expr>(expr)) ;
609 m_initialized = true ;
619 assign_value(boost::forward<Expr>(expr), is_reference_predicate());
629 new (m_storage.address()) internal_type(expr) ;
630 m_initialized = true ;
638 void assign_expr_to_initialized (
Expr const& expr,
void const* )
640 assign_value(expr, is_reference_predicate());
645 #ifdef BOOST_OPTIONAL_WEAK_OVERLOAD_RESOLUTION 658 #ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES 663 if ( expr.is_initialized() )
667 new (m_storage.address()) internal_type(
types::move(expr.get())) ;
668 m_initialized = true ;
676 if ( expr.is_initialized() )
680 new (m_storage.address()) internal_type(expr.get()) ;
681 m_initialized = true ;
685 #endif // defined BOOST_OPTIONAL_WEAK_OVERLOAD_RESOLUTION 689 #ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES 690 void assign_value ( rval_reference_type
val, is_not_reference_tag ) { get_impl() =
static_cast<rval_reference_type
>(
val); }
697 destroy_impl(is_reference_predicate()) ;
700 reference_const_type
get_impl()
const {
return dereference(get_object(), is_reference_predicate() ) ; }
701 reference_type
get_impl() {
return dereference(get_object(), is_reference_predicate() ) ; }
703 pointer_const_type
get_ptr_impl()
const {
return cast_ptr(get_object(), is_reference_predicate() ) ; }
704 pointer_type
get_ptr_impl() {
return cast_ptr(get_object(), is_reference_predicate() ) ; }
709 #if defined(BOOST_OPTIONAL_DETAIL_USE_ATTRIBUTE_MAY_ALIAS) 711 internal_type
const* get_object()
const 713 union {
void const* ap_pvoid; internal_type
const* as_ptype; } caster = { m_storage.address() };
714 return caster.as_ptype;
716 internal_type * get_object()
718 union {
void* ap_pvoid; internal_type* as_ptype; } caster = { m_storage.address() };
719 return caster.as_ptype;
722 internal_type
const*
get_object()
const {
return static_cast<internal_type const*
>(m_storage.address()); }
723 internal_type *
get_object() {
return static_cast<internal_type *
> (m_storage.address()); }
727 reference_const_type
dereference( internal_type
const*
p, is_not_reference_tag )
const {
return *
p ; }
728 reference_type
dereference( internal_type*
p, is_not_reference_tag ) {
return *
p ; }
729 reference_const_type
dereference( internal_type
const*
p, is_reference_tag )
const {
return p->get() ; }
730 reference_type
dereference( internal_type*
p, is_reference_tag ) {
return p->get() ; }
732 #if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x581)) 733 void destroy_impl ( is_not_reference_tag ) { get_ptr_impl()->internal_type::~internal_type() ; m_initialized = false ; }
735 void destroy_impl ( is_not_reference_tag ) { get_ptr_impl()->~T() ; m_initialized = false ; }
743 pointer_const_type
cast_ptr( internal_type
const*
p, is_not_reference_tag )
const {
return p ; }
744 pointer_type
cast_ptr( internal_type *
p, is_not_reference_tag ) {
return p ; }
745 pointer_const_type
cast_ptr( internal_type
const*
p, is_reference_tag )
const {
return &p->get() ; }
746 pointer_type
cast_ptr( internal_type *
p, is_reference_tag ) {
return &p->get() ; }
766 #ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES 786 #ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES 790 {optional_detail::prevent_binding_rvalue_ref_to_optional_lvalue_ref<T, rval_reference_type>();}
811 #ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES 820 if ( rhs.is_initialized() )
825 #ifndef BOOST_OPTIONAL_NO_INPLACE_FACTORY_SUPPORT 835 #ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES 845 {optional_detail::prevent_binding_rvalue_ref_to_optional_lvalue_ref<T, Expr&&>();}
850 #endif // !defined BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES 851 #endif // !defined BOOST_OPTIONAL_NO_INPLACE_FACTORY_SUPPORT 855 optional ( optional
const& rhs ) : base( static_cast<base const&>(rhs) ) {}
857 #ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES 869 #if !defined(BOOST_OPTIONAL_NO_INPLACE_FACTORY_SUPPORT) && !defined(BOOST_OPTIONAL_WEAK_OVERLOAD_RESOLUTION) 872 #ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES 882 optional_detail::prevent_binding_rvalue_ref_to_optional_lvalue_ref<T, Expr&&>();
889 optional& operator= (
Expr const& expr )
894 #endif // !defined BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES 895 #endif // !defined(BOOST_OPTIONAL_NO_INPLACE_FACTORY_SUPPORT) && !defined(BOOST_OPTIONAL_WEAK_OVERLOAD_RESOLUTION) 907 #ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES 922 optional& operator= ( optional
const& rhs )
924 this->assign( static_cast<base const&>(rhs) ) ;
928 #ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES 930 optional& operator= ( optional && rhs )
933 this->assign( static_cast<base &&>(rhs) ) ;
940 optional& operator= ( argument_type
val )
942 this->assign( val ) ;
946 #ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES 948 optional& operator= ( rval_reference_type
val )
950 optional_detail::prevent_binding_rvalue_ref_to_optional_lvalue_ref<T, rval_reference_type>();
961 this->assign( none_ ) ;
965 #if (!defined BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES) && (!defined BOOST_NO_CXX11_VARIADIC_TEMPLATES) 968 template<
class... Args>
971 this->emplace_assign( boost::forward<Args>(
args)... );
973 #elif (!defined BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES) 975 void emplace ( Arg&&
arg )
977 this->emplace_assign( boost::forward<Arg>(
arg) );
981 void emplace (
const Arg&
arg )
983 this->emplace_assign( arg );
987 void emplace ( Arg& arg )
989 this->emplace_assign( arg );
1004 reference_const_type
get()
const {
BOOST_ASSERT(this->is_initialized()) ;
return this->get_impl(); }
1005 reference_type
get() {
BOOST_ASSERT(this->is_initialized()) ;
return this->get_impl(); }
1008 reference_const_type
get_value_or ( reference_const_type
v )
const {
return this->is_initialized() ?
get() : v ; }
1009 reference_type
get_value_or ( reference_type
v ) {
return this->is_initialized() ?
get() : v ; }
1020 #if (!defined BOOST_NO_CXX11_REF_QUALIFIERS) && (!defined BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES) 1021 reference_const_type
operator *() const& {
return this->
get() ; }
1025 reference_const_type
operator *()
const {
return this->
get() ; }
1026 reference_type
operator *() {
return this->
get() ; }
1027 #endif // !defined BOOST_NO_CXX11_REF_QUALIFIERS 1029 #if (!defined BOOST_NO_CXX11_REF_QUALIFIERS) && (!defined BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES) 1032 if (this->is_initialized())
1033 return this->
get() ;
1040 if (this->is_initialized())
1041 return this->
get() ;
1046 reference_type_of_temporary_wrapper
value() &&
1048 if (this->is_initialized())
1055 reference_const_type
value()
const 1057 if (this->is_initialized())
1058 return this->
get() ;
1063 reference_type
value()
1065 if (this->is_initialized())
1066 return this->
get() ;
1073 #ifndef BOOST_NO_CXX11_REF_QUALIFIERS 1077 if (this->is_initialized())
1080 return boost::forward<U>(
v);
1086 if (this->is_initialized())
1089 return boost::forward<U>(
v);
1091 #elif !defined BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES 1093 value_type value_or ( U&&
v )
const 1095 if (this->is_initialized())
1098 return boost::forward<U>(
v);
1102 value_type value_or ( U
const&
v )
const 1104 if (this->is_initialized())
1111 value_type value_or ( U& v )
const 1113 if (this->is_initialized())
1121 #ifndef BOOST_NO_CXX11_REF_QUALIFIERS 1122 template <
typename F>
1125 if (this->is_initialized())
1131 template <
typename F>
1134 if (this->is_initialized())
1140 template <
typename F>
1141 value_type value_or_eval ( F
f )
const 1143 if (this->is_initialized())
1155 #ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES 1204 return opt->get_ptr() ;
1212 return opt->get_ptr() ;
1252 template<
class CharType,
class CharTrait>
1253 std::basic_ostream<CharType, CharTrait>&
1256 BOOST_STATIC_ASSERT_MSG(
sizeof(CharType) == 0,
"If you want to output boost::optional, include header <boost/optional/optional_io.hpp>");
1280 {
return !( x ==
y ) ; }
1290 {
return !( y <
x ) ; }
1295 {
return !( x <
y ) ; }
1308 bool operator < ( optional<T>
const&
x,
T const&
y )
1314 {
return !( x ==
y ) ; }
1323 bool operator <= ( optional<T>
const&
x,
T const&
y )
1324 {
return !( y <
x ) ; }
1329 {
return !( x <
y ) ; }
1342 bool operator < ( T const& x, optional<T>
const&
y )
1348 {
return !( x ==
y ) ; }
1357 bool operator <= ( T const& x, optional<T>
const&
y )
1358 {
return !( y <
x ) ; }
1363 {
return !( x <
y ) ; }
1393 {
return !( y <
x ) ; }
1398 {
return !( x <
y ) ; }
1411 bool operator < ( none_t , optional<T>
const&
y )
1426 bool operator <= ( none_t x, optional<T>
const&
y )
1427 {
return !( y <
x ) ; }
1432 {
return !( x <
y ) ; }
1434 namespace optional_detail {
1444 const bool hasX = !!
x;
1445 const bool hasY = !!
y;
1447 if ( !hasX && !hasY )
1451 x = boost::in_place();
1453 y = boost::in_place();
1465 #ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES 1502 const bool hasX = !!
x;
1503 const bool hasY = !!
y;
1505 if ( !hasX && hasY )
1510 else if ( hasX && !hasY )
1515 else if ( hasX && hasY )
1522 #endif // !defined BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES
BOOST_DEDUCED_TYPENAME types::pointer_type pointer_type
T const * pointer_const_type
raw_type & reference_type
void assign(rval_reference_type val)
pointer_const_type cast_ptr(internal_type const *p, is_reference_tag) const
reference_const_type get_value_or(reference_const_type v) const
BOOST_DEDUCED_TYPENAME types::rval_reference_type rval_reference_type
BOOST_FORCEINLINE T * addressof(T &v)
boost::detail::remove_rvalue_ref< T >::type type
boost_foreach_argument_dependent_lookup_hack tag
BOOST_DEDUCED_TYPENAME types::reference_const_type reference_const_type
boost::detail::decay_imp< Ty, boost::is_array< Ty >::value, boost::is_function< Ty >::value >::type type
optional(none_t none_) BOOST_NOEXCEPT
optional_base(Expr &&expr, PtrExpr const *tag)
BOOST_DEDUCED_TYPENAME base::pointer_type pointer_type
BOOST_DEDUCED_TYPENAME base::reference_const_type reference_const_type
void assign_expr(Expr &&expr, ExprPtr const *tag)
BOOST_MOVE_USE_STANDARD_LIBRARY_MOVE.
optional_base(rval_reference_type val)
bool operator!=(failed, failed)
optional() BOOST_NOEXCEPT
optional(argument_type val)
reference_type get_impl()
BOOST_DEDUCED_TYPENAME mpl::if_< is_reference_predicate, types_when_ref, types_when_not_ref >::type types
reference_type dereference(internal_type *p, is_reference_tag)
types_when_isnt_ref< T > types_when_not_ref
ImVec4 operator*(const ImVec4 &color, float t)
optional(optional< U > &&rhs)
void destroy_impl(is_reference_tag)
BOOST_NORETURN void throw_exception(E const &e)
T const & reference_const_type
void emplace(Args &&...args)
reference_const_type dereference(internal_type const *p, is_reference_tag) const
raw_type & reference_type_of_temporary_wrapper
pointer_type operator->()
types_when_is_ref< T > types_when_ref
void assign_expr_to_initialized(Expr &&factory, typed_in_place_factory_base const *tag)
bool operator>(failed, failed)
reference_type get_value_or(reference_type v)
static reference_type move(reference_type r)
pointer_type get_ptr_impl()
value_type value_or(U &&v) const &
void construct(Expr &&factory, in_place_factory_base const *)
value_type value_or_eval(F f) const &
void construct(rval_reference_type val)
optional(optional &&rhs) BOOST_NOEXCEPT_IF(
static void destroy(const mxArray *cell)
void assign_expr_to_initialized(Expr &&expr, void const *)
BOOST_DEDUCED_TYPENAME optional< T >::pointer_type get_pointer(optional< T > &opt)
raw_type * pointer_const_type
optional_base(optional_base &&rhs)
void construct(argument_type val)
void assign(optional_base const &rhs)
BOOST_DEDUCED_TYPENAME base::pointer_const_type pointer_const_type
bool equal_pointees(OptionalPointee const &x, OptionalPointee const &y)
reference_const_type get() const
BOOST_DEDUCED_TYPENAME optional< T >::reference_type get_optional_value_or(optional< T > &opt, BOOST_DEDUCED_TYPENAME optional< T >::reference_type v)
BOOST_DEDUCED_TYPENAME base::rval_reference_type rval_reference_type
void assign(optional< U > const &rhs)
optional_base< T > this_type
optional< T > make_optional(bool cond, T const &v)
static void optional_swap(optional< T > &x, optional< T > &y)
pointer_const_type get_ptr() const
optional(Expr &&expr, BOOST_DEDUCED_TYPENAME boost::disable_if_c< (boost::is_base_of< optional_detail::optional_tag, BOOST_DEDUCED_TYPENAME boost::decay< Expr >::type >::value)||boost::is_same< BOOST_DEDUCED_TYPENAME boost::decay< Expr >::type, none_t >::value >::type *=0)
void reset(argument_type val)
#define BOOST_DEDUCED_TYPENAME
BOOST_DEDUCED_TYPENAME base::reference_type reference_type
void swap(optional< T > &x, optional< T > &y)
BOOST_DEDUCED_TYPENAME base::value_type value_type
T && forward(typename::boost::move_detail::remove_reference< T >::type &t) BOOST_NOEXCEPT
mpl::false_ is_not_reference_tag
void prevent_binding_rvalue_ref_to_optional_lvalue_ref()
void assign_value(argument_type val, is_not_reference_tag)
T && reference_type_of_temporary_wrapper
void const * address() const
reference_const_type dereference(internal_type const *p, is_not_reference_tag) const
pointer_type cast_ptr(internal_type *p, is_reference_tag)
internal_type const * get_object() const
BOOST_DEDUCED_TYPENAME base::argument_type argument_type
void emplace_assign(Args &&...args)
void assign_expr_to_initialized(Expr &&factory, in_place_factory_base const *tag)
reference_const_type value() const &
BOOST_DEDUCED_TYPENAME remove_const< raw_type >::type && rval_reference_type
BOOST_DEDUCED_TYPENAME types::argument_type argument_type
void destroy_impl(is_not_reference_tag)
bool less_pointees(OptionalPointee const &x, OptionalPointee const &y)
void assign(optional_base &&rhs)
void reset() BOOST_NOEXCEPT
void assign(optional< U > &&rhs)
internal_type * get_object()
mpl::true_ is_reference_tag
void assign_value(rval_reference_type val, is_reference_tag)
void construct(Factory const &factory, void *address)
pointer_type cast_ptr(internal_type *p, is_not_reference_tag)
#define BOOST_STATIC_ASSERT(...)
BOOST_DEDUCED_TYPENAME::boost::detail::make_reference_content< T >::type internal_type
BOOST_GPU_ENABLED void swap(T1 &left, T2 &right)
optional(optional< U > const &rhs)
void assign_value(rval_reference_type val, is_not_reference_tag)
void construct(Expr &&expr, void const *)
optional_base(optional_base const &rhs)
reference_type dereference(internal_type *p, is_not_reference_tag)
#define BOOST_STATIC_ASSERT_MSG(...)
BOOST_DEDUCED_TYPENAME is_reference< T >::type is_reference_predicate
static rval_reference_type move(reference_type r)
#define BOOST_NOEXCEPT_IF(Predicate)
bool operator>=(failed, failed)
optional_detail::optional_base< T > base
void swap(optional &arg) BOOST_NOEXCEPT_IF(
raw_type & reference_const_type
GLuint GLuint64EXT address
typename::boost::move_detail::remove_reference< T >::type && move(T &&t) BOOST_NOEXCEPT
bool is_initialized() const
BOOST_DEDUCED_TYPENAME base::reference_type_of_temporary_wrapper reference_type_of_temporary_wrapper
pointer_const_type get_ptr_impl() const
value_type value_or(U &&v)&&
pointer_const_type cast_ptr(internal_type const *p, is_not_reference_tag) const
void construct(Expr &&factory, typed_in_place_factory_base const *)
optional(optional const &rhs)
BOOST_DEDUCED_TYPENAME types::reference_type_of_temporary_wrapper reference_type_of_temporary_wrapper
BOOST_DEDUCED_TYPENAME types::pointer_const_type pointer_const_type
#define BOOST_ASSERT(expr)
reference_const_type get_impl() const
void assign_value(argument_type val, is_reference_tag)
#define BOOST_EXPLICIT_OPERATOR_BOOL_NOEXCEPT()
The macro defines a noexcept explicit operator of conversion to bool.
reference_type_of_temporary_wrapper value()&&
BOOST_DEDUCED_TYPENAME types::reference_type reference_type
bool operator==(none_t, optional< T > const &y) BOOST_NOEXCEPT
aligned_storage< internal_type > storage_type
static void optional_swap(optional< T > &x, optional< T > &y)
void assign(argument_type val)
BOOST_DEDUCED_TYPENAME remove_reference< T >::type raw_type
optional(rval_reference_type val)
optional(bool cond, argument_type val)
void assign(none_t) BOOST_NOEXCEPT
BOOST_DEDUCED_TYPENAME type_with_alignment< ::boost::alignment_of< T >::value >::type aligner_
optional_base(argument_type val)
value_type value_or_eval(F f)&&
optional_base(bool cond, argument_type val)
pointer_const_type operator->() const
bool operator!() const BOOST_NOEXCEPT