![]() |
Home | Libraries | People | FAQ | More |
boost::movelib::default_delete
// In header: <boost/move/default_delete.hpp> template<typename T> struct default_delete { // construct/copy/destruct (); (default_delete &); template<typename U> (default_delete< ) ; default_delete & (default_delete &); template<typename U> default_delete & (default_delete< ) ; // public member functions template<typename U> () ; () ; };
The class template default_delete
serves as the default deleter (destruction policy) for the class template unique_ptr
.
default_delete
public
construct/copy/destruct();
Default constructor.
(default_delete &);
Trivial copy constructor
template<typename U> (default_delete< BOOST_MOVE_DOCIGN) ;
Effects: Constructs a default_delete
object from another default_delete
<underline> object.</underline>
If T is not an array type and U* is implicitly convertible to T*. If T is an array type and U* is a more CV qualified pointer to remove_extent<T>::type. <underline>Remarks: This constructor shall not participate in overload resolution unless:
default_delete & (default_delete &);
Trivial assignment
template<typename U> default_delete & (default_delete< ) ;
Effects: Constructs a default_delete
object from another default_delete
<underline> object.</underline>
If T is not an array type and U* is implicitly convertible to T*. If T is an array type and U* is a more CV qualified pointer to remove_extent<T>::type. <underline>Remarks: This constructor shall not participate in overload resolution unless:
default_delete
public member functionstemplate<typename U> ( ptr) ;
Effects: if T is not an array type, calls delete
on static_cast<T*>(ptr), otherwise calls delete[]
on static_cast<remove_extent<T>::type*>(ptr).
Remarks: If U is an incomplete type, the program is ill-formed. This operator shall not participate in overload resolution unless:
T is not an array type and U* is convertible to T*, OR
T is an array type, and remove_cv<U>::type is the same type as remove_cv<remove_extent<T>::type>::type and U* is convertible to remove_extent<T>::type*.
() ;
Effects: Same as (this)(static_cast<element_type>(nullptr))
.