1 #if !defined(RECURSIVE_WRAPPER_77D62153_38D6_4311_8B5C_384D740BDF6E_H)
2 # define RECURSIVE_WRAPPER_77D62153_38D6_4311_8B5C_384D740BDF6E_H
20 class recursive_wrapper;
62 using recursive_wrapper_unwrap_t =
67 template <
class T,
class U>
76 template <
class T,
class U>
120 type const& get() const;
122 type const* get_pointer() const;
129 return lhs.get () == rhs.get ();
137 return !(lhs.
get () == rhs.
get ());
146 template <
class... Args>
153 p_ (new T (rhs.get ())) {
162 p_ (new T (
std::
move (rhs.get ()))) {
175 recursive_wrapper<T>&
177 return assign (rhs.get());
186 recursive_wrapper<T>& recursive_wrapper<T>::assign (T
const& rhs) {
187 this->
get() = rhs;
return *
this;
196 recursive_wrapper<T>&
203 recursive_wrapper<T>&
209 template <
typename T>
211 recursive_wrapper<T>& lhs, recursive_wrapper<T>& rhs) noexcept {
215 template <
typename T>
218 template <
typename T>
221 template <
typename T>
224 template <
typename T>
recursive_wrapper(Args &&...args)
Forwarding ctor (heap allocates type instance)
Primary template of a metafunction to classify a type as recursive_wrapper<> or not.
Definition: recursive_wrapper.hpp:29
void swap(recursive_wrapper &rhs) noexcept
Swap with recursive_wrapper
Parameter pack conjunction.
Definition: logical.hpp:83
T type
For T not a recursive wrapper.
Definition: recursive_wrapper.hpp:48
Definition: logical.hpp:13
type & get()
Accessor to the type instance.
Definition: type_traits.hpp:26
~recursive_wrapper()
Destructor (frees heap-allocated type instance)
T type
Alias type for T
Definition: recursive_wrapper.hpp:90
T type
Definition: recursive_wrapper.hpp:55
At this time contains only a metafunction for determining if a given type F is "callable" on a parame...
types
Definition: recursive_wrapper.hpp:82
Primary template of a metafunction to compute the type contained by a recursive_wrapper<>.
Definition: recursive_wrapper.hpp:47
type * get_pointer()
Accessor to the type instance.
recursive_wrapper & operator=(recursive_wrapper const &rhs)
Copy-assign from recursive_wrapper