view release on metacpan or search on metacpan
360136023603360436053606360736083609361036113612361336143615361636173618361936203621src/boost/utility/enable_if.hpp
src/boost/utility/identity_type.hpp
src/boost/utility/in_place_factory.hpp
src/boost/utility/result_of.hpp
src/boost/utility/swap.hpp
src/boost/utility/value_init.hpp
src/boost/variant/apply_visitor.hpp
src/boost/variant/detail/apply_visitor_binary.hpp
src/boost/variant/detail/apply_visitor_delayed.hpp
src/boost/variant/detail/apply_visitor_unary.hpp
src/boost/variant/detail/backup_holder.hpp
src/boost/variant/detail/bool_trait_def.hpp
src/boost/variant/detail/bool_trait_undef.hpp
src/boost/variant/detail/cast_storage.hpp
src/boost/variant/detail/config.hpp
src/boost/variant/detail/enable_recursive_fwd.hpp
src/boost/variant/detail/forced_return.hpp
src/boost/variant/detail/generic_result_type.hpp
src/boost/variant/detail/has_nothrow_move.hpp
src/boost/variant/detail/has_trivial_move.hpp
src/boost/variant/detail/hash_variant.hpp
src/boost/variant/detail/backup_holder.hpp view on Meta::CPAN
1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495//-----------------------------------------------------------------------------
// boost variant/detail/backup_holder.hpp header file
//-----------------------------------------------------------------------------
//
// Copyright (c) 2003
// Eric Friedman
//
// Distributed under the Boost Software License, Version 1.0. (See
// accompanying file LICENSE_1_0.txt or copy at
#ifndef BOOST_VARIANT_DETAIL_BACKUP_HOLDER_HPP
#define BOOST_VARIANT_DETAIL_BACKUP_HOLDER_HPP
#include "boost/config.hpp"
#include "boost/assert.hpp"
namespace boost {
namespace detail { namespace variant {
template <typename T>
class backup_holder
{
private: // representation
T* backup_;
public: // structors
~backup_holder()
{
delete
backup_;
}
explicit backup_holder(T* backup) BOOST_NOEXCEPT
: backup_(backup)
{
}
backup_holder(const backup_holder&);
public: // modifiers
backup_holder& operator=(const backup_holder& rhs)
{
*backup_
= rhs.get();
return
*this
;
}
backup_holder& operator=(const T& rhs)
{
*backup_
= rhs;
return
*this
;
}
void swap(backup_holder& rhs) BOOST_NOEXCEPT
{
T* tmp = rhs.backup_;
rhs.backup_ = this->backup_;
this->backup_ = tmp;
}
public: // queries
T& get()
{
return
*backup_
;
}
const T& get() const
{
return
*backup_
;
}
};
template <typename T>
backup_holder<T>::backup_holder(const backup_holder&)
: backup_(0)
{
// not intended
for
copy, but
do
not want to prohibit syntactically
BOOST_ASSERT(false);
}
template <typename T>
void swap(backup_holder<T>& lhs, backup_holder<T>& rhs) BOOST_NOEXCEPT
{
lhs.swap(rhs);
}
}} // namespace detail::variant
} // namespace boost
#endif // BOOST_VARIANT_DETAIL_BACKUP_HOLDER_HPP
src/boost/variant/detail/visitation_impl.hpp view on Meta::CPAN
8910111213141516171819202122232425262728//
// Distributed under the Boost Software License, Version 1.0. (See
// accompanying file LICENSE_1_0.txt or copy at
#ifndef BOOST_VARIANT_DETAIL_VISITATION_IMPL_HPP
#define BOOST_VARIANT_DETAIL_VISITATION_IMPL_HPP
#include "boost/config.hpp"
#include "boost/variant/detail/backup_holder.hpp"
#include "boost/variant/detail/cast_storage.hpp"
#include "boost/variant/detail/forced_return.hpp"
#include "boost/variant/detail/generic_result_type.hpp"
#include "boost/assert.hpp"
#include "boost/mpl/eval_if.hpp"
#include "boost/mpl/bool.hpp"
#include "boost/mpl/identity.hpp"
#include "boost/mpl/int.hpp"
#include "boost/mpl/next.hpp"
src/boost/variant/detail/visitation_impl.hpp view on Meta::CPAN
115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182// (detail) function template visitation_impl_invoke
//
// Invokes the
given
visitor on the specified type in the
given
storage.
//
template <typename Visitor, typename VoidPtrCV, typename T>
inline
BOOST_VARIANT_AUX_GENERIC_RESULT_TYPE(typename Visitor::result_type)
visitation_impl_invoke_impl(
int
, Visitor& visitor, VoidPtrCV storage, T*
, mpl::true_// never_uses_backup
)
{
return
visitor.internal_visit(
cast_storage<T>(storage), 1L
);
}
template <typename Visitor, typename VoidPtrCV, typename T>
inline
BOOST_VARIANT_AUX_GENERIC_RESULT_TYPE(typename Visitor::result_type)
visitation_impl_invoke_impl(
int
internal_which, Visitor& visitor, VoidPtrCV storage, T*
, mpl::false_// never_uses_backup
)
{
if
(internal_which >= 0)
{
return
visitor.internal_visit(
cast_storage<T>(storage), 1L
);
}
else
{
return
visitor.internal_visit(
cast_storage< backup_holder<T> >(storage), 1L
);
}
}
template <typename Visitor, typename VoidPtrCV, typename T, typename NoBackupFlag>
inline
BOOST_VARIANT_AUX_GENERIC_RESULT_TYPE(typename Visitor::result_type)
visitation_impl_invoke(
int
internal_which, Visitor& visitor, VoidPtrCV storage, T* t
, NoBackupFlag
,
int
)
{
typedef typename mpl::or_<
NoBackupFlag
, has_nothrow_move_constructor<T>
, has_nothrow_copy<T>
>::type never_uses_backup;
return
(visitation_impl_invoke_impl)(
internal_which, visitor, storage, t
, never_uses_backup()
);
}
template <typename Visitor, typename VoidPtrCV, typename NBF>
inline
BOOST_VARIANT_AUX_GENERIC_RESULT_TYPE(typename Visitor::result_type)
visitation_impl_invoke(
int
, Visitor&, VoidPtrCV, apply_visitor_unrolled*, NBF, long)
{
// should never be here at runtime:
BOOST_ASSERT(false);
src/boost/variant/detail/visitation_impl.hpp view on Meta::CPAN
213214215216217218219220221222223224225226227228229230231232
typename Which, typename step0
, typename Visitor, typename VoidPtrCV
, typename NoBackupFlag
>
inline
BOOST_VARIANT_AUX_GENERIC_RESULT_TYPE(typename Visitor::result_type)
visitation_impl(
const
int
internal_which, const
int
logical_which
, Visitor& visitor, VoidPtrCV storage
, mpl::false_ // is_apply_visitor_unrolled
, NoBackupFlag no_backup_flag
, Which* = 0, step0* = 0
)
{
// Typedef apply_visitor_unrolled steps and associated types...
# define BOOST_VARIANT_AUX_APPLY_VISITOR_STEP_TYPEDEF(z, N, _) \
typedef typename BOOST_PP_CAT(step,N)::type BOOST_PP_CAT(T,N); \
typedef typename BOOST_PP_CAT(step,N)::
next
\
BOOST_PP_CAT(step, BOOST_PP_INC(N)); \
/**/
src/boost/variant/detail/visitation_impl.hpp view on Meta::CPAN
242243244245246247248249250251252253254255256257258259260261262
// ...switch on the target which-
index
value...
switch (logical_which)
{
// ...applying the appropriate case:
# define BOOST_VARIANT_AUX_APPLY_VISITOR_STEP_CASE(z, N, _) \
case (Which::value + (N)): \
return
(visitation_impl_invoke)( \
internal_which, visitor, storage \
, static_cast<BOOST_PP_CAT(T,N)*>(0) \
, no_backup_flag, 1L \
); \
/**/
BOOST_PP_REPEAT(
BOOST_VARIANT_VISITATION_UNROLLING_LIMIT
, BOOST_VARIANT_AUX_APPLY_VISITOR_STEP_CASE
, _
)
# undef BOOST_VARIANT_AUX_APPLY_VISITOR_STEP_CASE
src/boost/variant/detail/visitation_impl.hpp view on Meta::CPAN
273274275276277278279280281282283284285286287288289290291292293
next_step;
typedef typename next_step::type next_type;
typedef typename is_same< next_type,apply_visitor_unrolled >::type
is_apply_visitor_unrolled;
return
visitation_impl(
internal_which, logical_which
, visitor, storage
, is_apply_visitor_unrolled()
, no_backup_flag
, static_cast<next_which*>(0), static_cast<next_step*>(0)
);
}
}} // namespace detail::variant
} // namespace boost
#if BOOST_WORKAROUND(BOOST_MSVC, >= 1400)
# pragma warning(pop)
#endif
src/boost/variant/variant.hpp view on Meta::CPAN
181920212223242526272829303132333435363738#if !defined(BOOST_NO_TYPEID)
#include <typeinfo> // for typeid, std::type_info
#endif // BOOST_NO_TYPEID
#include "boost/variant/detail/config.hpp"
#include "boost/mpl/aux_/config/eti.hpp"
#include "boost/mpl/aux_/value_wknd.hpp"
#include "boost/variant/variant_fwd.hpp"
#include "boost/variant/detail/backup_holder.hpp"
#include "boost/variant/detail/enable_recursive_fwd.hpp"
#include "boost/variant/detail/forced_return.hpp"
#include "boost/variant/detail/initializer.hpp"
#include "boost/variant/detail/make_variant_list.hpp"
#include "boost/variant/detail/over_sequence.hpp"
#include "boost/variant/detail/visitation_impl.hpp"
#include "boost/variant/detail/hash_variant.hpp"
#include "boost/variant/detail/generic_result_type.hpp"
#include "boost/variant/detail/has_nothrow_move.hpp"
src/boost/variant/variant.hpp view on Meta::CPAN
235236237238239240241242243244245246247248249250251252253254255template <typename Types, typename NeverUsesBackupFlag>
struct make_storage
{
private: // helpers,
for
metafunction result (below)
typedef typename mpl::eval_if<
NeverUsesBackupFlag
, mpl::identity< Types >
, mpl::push_front<
Types, backup_holder<void*>
>
>::type types;
typedef typename max_value<
types, mpl::sizeof_<mpl::_1>
>::type max_size;
#if !BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x0551))
typedef typename mpl::fold<
src/boost/variant/variant.hpp view on Meta::CPAN
401402403404405406407408409410411412413414415416417418419420421422423424425426427428429
explicit copy_into(void* storage) BOOST_NOEXCEPT
: storage_(storage)
{
}
public: // internal visitor interface
template <typename T>
BOOST_VARIANT_AUX_RETURN_VOID_TYPE
internal_visit(boost::detail::variant::backup_holder<T>& operand, long) const
{
new(storage_) T( operand.get() );
BOOST_VARIANT_AUX_RETURN_VOID;
}
template <typename T>
BOOST_VARIANT_AUX_RETURN_VOID_TYPE
internal_visit(const boost::detail::variant::backup_holder<T>& operand, long) const
{
new(storage_) T( operand.get() );
BOOST_VARIANT_AUX_RETURN_VOID;
}
template <typename T>
BOOST_VARIANT_AUX_RETURN_VOID_TYPE
internal_visit(const T& operand,
int
) const
{
new(storage_) T(operand);
src/boost/variant/variant.hpp view on Meta::CPAN
449450451452453454455456457458459460461462463464465466467468469
explicit move_into(void* storage) BOOST_NOEXCEPT
: storage_(storage)
{
}
public: // internal visitor interface
template <typename T>
BOOST_VARIANT_AUX_RETURN_VOID_TYPE
internal_visit(boost::detail::variant::backup_holder<T>& operand, long) const
{
new(storage_) T( ::boost::detail::variant::move(operand.get()) );
BOOST_VARIANT_AUX_RETURN_VOID;
}
template <typename T>
BOOST_VARIANT_AUX_RETURN_VOID_TYPE
internal_visit(T& operand,
int
) const BOOST_NOEXCEPT_IF(BOOST_NOEXCEPT_EXPR(T(boost::declval<T>())))
{
new(storage_) T(::boost::detail::variant::move(operand));
src/boost/variant/variant.hpp view on Meta::CPAN
489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521
explicit assign_storage(const void* rhs_storage) BOOST_NOEXCEPT
: rhs_storage_(rhs_storage)
{
}
public: // internal visitor interfaces
template <typename T>
BOOST_VARIANT_AUX_RETURN_VOID_TYPE
internal_visit(backup_holder<T>& lhs_content, long) const
{
lhs_content.get()
= static_cast< const backup_holder<T>* >(rhs_storage_)->get();
BOOST_VARIANT_AUX_RETURN_VOID;
}
template <typename T>
BOOST_VARIANT_AUX_RETURN_VOID_TYPE
internal_visit(const backup_holder<T>& lhs_content, long) const
{
lhs_content.get()
= static_cast< const backup_holder<T>* >(rhs_storage_)->get();
BOOST_VARIANT_AUX_RETURN_VOID;
}
template <typename T>
BOOST_VARIANT_AUX_RETURN_VOID_TYPE
internal_visit(T& lhs_content,
int
) const
{
// NOTE TO USER :
// Compile error here indicates one of variant's bounded types does
// not meet the requirements of the Assignable concept. Thus,
src/boost/variant/variant.hpp view on Meta::CPAN
546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578
explicit move_storage(void* rhs_storage) BOOST_NOEXCEPT
: rhs_storage_(rhs_storage)
{
}
public: // internal visitor interfaces
template <typename T>
BOOST_VARIANT_AUX_RETURN_VOID_TYPE
internal_visit(backup_holder<T>& lhs_content, long) const
{
lhs_content.get()
= ::boost::detail::variant::move(static_cast<backup_holder<T>* >(rhs_storage_)->get());
BOOST_VARIANT_AUX_RETURN_VOID;
}
template <typename T>
BOOST_VARIANT_AUX_RETURN_VOID_TYPE
internal_visit(const backup_holder<T>& lhs_content, long) const
{
lhs_content.get()
= ::boost::detail::variant::move(static_cast<backup_holder<T>* >(rhs_storage_)->get());
BOOST_VARIANT_AUX_RETURN_VOID;
}
template <typename T>
BOOST_VARIANT_AUX_RETURN_VOID_TYPE
internal_visit(T& lhs_content,
int
) const
{
// NOTE TO USER :
// Compile error here indicates one of variant's bounded types does
// not meet the requirements of the Assignable concept. Thus,
src/boost/variant/variant.hpp view on Meta::CPAN
711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858#if BOOST_WORKAROUND(BOOST_MSVC, BOOST_TESTED_AT(1600))
private:
// silence MSVC warning C4512: assignment operator could not be generated
direct_mover& operator= (direct_mover const&);
#endif
};
///////////////////////////////////////////////////////////////////////////////
// (detail) class backup_assigner
//
// Internal visitor that
"assigns"
the
given
value to the visited value,
// using backup to recover
if
the destroy-copy sequence fails.
//
// NOTE: This needs to be a friend of variant, as it needs access to
// indicate_which, indicate_backup_which, etc.
//
template <typename Variant>
class backup_assigner
: public static_visitor<>
{
private: // representation
Variant& lhs_;
int
rhs_which_;
const void* rhs_content_;
void (
*copy_rhs_content_
)(void*, const void*);
public: // structors
template<class RhsT>
backup_assigner(Variant& lhs,
int
rhs_which, const RhsT& rhs_content)
: lhs_(lhs)
, rhs_which_(rhs_which)
, rhs_content_(
&rhs_content
)
, copy_rhs_content_(
&construct_impl
<RhsT>)
{
}
private: // helpers,
for
visitor interface (below)
template<class RhsT>
static void construct_impl(void* addr, const void* obj)
{
new(addr) RhsT(
*static_cast
<const RhsT*>(obj));
}
template <typename LhsT>
void backup_assign_impl(
LhsT& lhs_content
, mpl::true_// has_nothrow_move
)
{
// Move lhs content to backup...
LhsT backup_lhs_content(
::boost::detail::variant::move(lhs_content)
); // nothrow
// ...destroy lhs content...
lhs_content.~LhsT(); // nothrow
try
{
// ...and attempt to copy rhs content into lhs storage:
copy_rhs_content_(lhs_.storage_.address(), rhs_content_);
}
catch
(...)
{
// In case of failure, restore backup content to lhs storage...
new(lhs_.storage_.address())
LhsT(
::boost::detail::variant::move(backup_lhs_content)
); // nothrow
// ...and rethrow:
throw;
}
// In case of success, indicate new content type:
lhs_.indicate_which(rhs_which_); // nothrow
}
template <typename LhsT>
void backup_assign_impl(
LhsT& lhs_content
, mpl::false_// has_nothrow_move
)
{
// Backup lhs content...
LhsT* backup_lhs_ptr = new LhsT(lhs_content);
// ...destroy lhs content...
lhs_content.~LhsT(); // nothrow
try
{
// ...and attempt to copy rhs content into lhs storage:
copy_rhs_content_(lhs_.storage_.address(), rhs_content_);
}
catch
(...)
{
// In case of failure, copy backup pointer to lhs storage...
new(lhs_.storage_.address())
backup_holder<LhsT>( backup_lhs_ptr ); // nothrow
// ...indicate now using backup...
lhs_.indicate_backup_which( lhs_.which() ); // nothrow
// ...and rethrow:
throw;
}
// In case of success, indicate new content type...
lhs_.indicate_which(rhs_which_); // nothrow
// ...and
delete
backup:
delete
backup_lhs_ptr; // nothrow
}
public: // visitor interface
template <typename LhsT>
BOOST_VARIANT_AUX_RETURN_VOID_TYPE
internal_visit(LhsT& lhs_content,
int
)
{
typedef typename has_nothrow_move_constructor<LhsT>::type
nothrow_move;
backup_assign_impl( lhs_content, nothrow_move() );
BOOST_VARIANT_AUX_RETURN_VOID;
}
#if BOOST_WORKAROUND(BOOST_MSVC, BOOST_TESTED_AT(1600))
private:
// silence MSVC warning C4512: assignment operator could not be generated
backup_assigner& operator= (backup_assigner const&);
#endif
};
///////////////////////////////////////////////////////////////////////////////
// (detail) class swap_with
//
// Visitor that swaps visited value
with
content of
given
variant.
//
// Precondition: Given variant MUST have same logical type as visited value.
//
src/boost/variant/variant.hpp view on Meta::CPAN
1083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110
template <typename T>
BOOST_VARIANT_AUX_GENERIC_RESULT_TYPE(result_type)
internal_visit(const boost::detail::reference_content<T>& operand, long)
{
return
internal_visit( operand.get(), 1L );
}
template <typename T>
BOOST_VARIANT_AUX_GENERIC_RESULT_TYPE(result_type)
internal_visit(boost::detail::variant::backup_holder<T>& operand, long)
{
return
internal_visit( operand.get(), 1L );
}
template <typename T>
BOOST_VARIANT_AUX_GENERIC_RESULT_TYPE(result_type)
internal_visit(const boost::detail::variant::backup_holder<T>& operand, long)
{
return
internal_visit( operand.get(), 1L );
}
#if BOOST_WORKAROUND(BOOST_MSVC, BOOST_TESTED_AT(1600))
private:
// silence MSVC warning C4512: assignment operator could not be generated
invoke_visitor& operator= (invoke_visitor const&);
#endif
};
src/boost/variant/variant.hpp view on Meta::CPAN
127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305
fallback_type_;
struct has_fallback_type_
: mpl::not_<
is_same< fallback_type_, detail::variant::no_fallback_type >
>
{
};
typedef has_fallback_type_
never_uses_backup_flag;
typedef typename detail::variant::make_storage<
internal_types, never_uses_backup_flag
>::type storage_t;
private: // helpers,
for
representation (below)
// which_ on:
// * [0, size<internal_types>) indicates stack content
// * [-size<internal_types>, 0) indicates pointer to heap backup
//
if
which_ >= 0:
// * then which() -> which_
// *
else
which() -> -(which_ + 1)
#if !defined(BOOST_VARIANT_MINIMIZE_SIZE)
typedef
int
which_t;
#else // defined(BOOST_VARIANT_MINIMIZE_SIZE)
src/boost/variant/variant.hpp view on Meta::CPAN
13261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363#endif
which_t which_;
storage_t storage_;
void indicate_which(
int
which_arg) BOOST_NOEXCEPT
{
which_ = static_cast<which_t>( which_arg );
}
void indicate_backup_which(
int
which_arg) BOOST_NOEXCEPT
{
which_ = static_cast<which_t>( -(which_arg + 1) );
}
private: // helpers,
for
queries (below)
bool using_backup() const BOOST_NOEXCEPT
{
return
which_ < 0;
}
public: // queries
int
which() const BOOST_NOEXCEPT
{
// If using heap backup...
if
(using_backup())
// ...then
return
adjusted which_:
return
-(which_ + 1);
// Otherwise,
return
which_ directly:
return
which_;
}
private: // helpers,
for
structors (below)
struct initializer
src/boost/variant/variant.hpp view on Meta::CPAN
14341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459
return
internal_visit( operand.get(), 1L );
}
template <typename T>
int
internal_visit(const boost::detail::reference_content<T>& operand, long) const
{
return
internal_visit( operand.get(), 1L );
}
template <typename T>
int
internal_visit(boost::detail::variant::backup_holder<T>& operand, long) const
{
return
internal_visit( operand.get(), 1L );
}
template <typename T>
int
internal_visit(const boost::detail::variant::backup_holder<T>& operand, long) const
{
return
internal_visit( operand.get(), 1L );
}
template <typename T>
int
internal_visit(boost::recursive_wrapper<T>& operand, long) const
{
return
internal_visit( operand.get(), 1L );
}
src/boost/variant/variant.hpp view on Meta::CPAN
15021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527
return
internal_visit( operand.get(), 1L );
}
template <typename T>
int
internal_visit(const boost::detail::reference_content<T>& operand, long) const
{
return
internal_visit( operand.get(), 1L );
}
template <typename T>
int
internal_visit(boost::detail::variant::backup_holder<T>& operand, long) const
{
return
internal_visit( operand.get(), 1L );
}
template <typename T>
int
internal_visit(const boost::detail::variant::backup_holder<T>& operand, long) const
{
return
internal_visit( operand.get(), 1L );
}
template <typename T>
int
internal_visit(boost::recursive_wrapper<T>& operand, long) const
{
return
internal_visit( operand.get(), 1L );
}
src/boost/variant/variant.hpp view on Meta::CPAN
177417751776177717781779178017811782178317841785178617871788178917901791179217931794
// ...and activate the
*this
's primary storage on success:
indicate_which(operand.which());
}
#endif
private: // helpers,
for
modifiers (below)
# if !defined(BOOST_NO_MEMBER_TEMPLATE_FRIENDS)
template <typename Variant>
friend class detail::variant::backup_assigner;
# endif
// class assigner
//
// Internal visitor that
"assigns"
the visited value to the
given
variant
// by appropriate destruction and copy-construction.
//
class assigner
: public static_visitor<>
src/boost/variant/variant.hpp view on Meta::CPAN
188618871888188918901891189218931894189518961897189818991900190119021903190419051906
}
template <typename RhsT>
void assign_impl(
const RhsT& rhs_content
, mpl::false_// has_nothrow_copy
, mpl::false_// has_nothrow_move_constructor
, mpl::false_// has_fallback_type
)
{
detail::variant::backup_assigner<wknd_self_t>
visitor(lhs_, rhs_which_, rhs_content);
lhs_.internal_apply_visitor(visitor);
}
public: // internal visitor interfaces
template <typename RhsT>
BOOST_VARIANT_AUX_RETURN_VOID_TYPE
internal_visit(const RhsT& rhs_content,
int
)
{
src/boost/variant/variant.hpp view on Meta::CPAN
203020312032203320342035203620372038203920402041204220432044204520462047204820492050
}
template <typename RhsT>
void assign_impl(
const RhsT& rhs_content
, mpl::false_// has_nothrow_copy
, mpl::false_// has_nothrow_move_constructor
, mpl::false_// has_fallback_type
)
{
detail::variant::backup_assigner<wknd_self_t>
visitor(lhs_, rhs_which_, rhs_content);
lhs_.internal_apply_visitor(visitor);
}
public: // internal visitor interfaces
template <typename RhsT>
BOOST_VARIANT_AUX_RETURN_VOID_TYPE
internal_visit(RhsT& rhs_content,
int
)
{
src/boost/variant/variant.hpp view on Meta::CPAN
231423152316231723182319232023212322232323242325232623272328232923302331233223332334
typedef typename mpl::begin<internal_types>::type first_it;
typedef typename mpl::end<internal_types>::type last_it;
typedef detail::variant::visitation_impl_step<
first_it, last_it
> first_step;
return
detail::variant::visitation_impl(
internal_which, logical_which
, visitor, storage, mpl::false_()
, never_uses_backup_flag()
, static_cast<first_which*>(0), static_cast<first_step*>(0)
);
}
template <typename Visitor>
BOOST_VARIANT_AUX_GENERIC_RESULT_TYPE(
typename Visitor::result_type
)
internal_apply_visitor(Visitor& visitor)
{