Assignment operators
Synopses
Declared in <bslstl_function.h>
Copy‐assign the target from rhs and return *this.
bsl::function<PROTOTYPE>&
operator=(function const& rhs);
Set this object to empty and return *this.
bsl::function<PROTOTYPE>&
operator=(nullptr_t unused) noexcept;
Move‐assign the target from rhs and return *this.
Assign from a reference_wrapper target and return *this.
template<class FUNC>
function&
operator=(bsl::reference_wrapper<FUNC> rhs) noexcept
requires IsInvocableWithPrototype<typename Decay<FUNC>::type>::value;
Assign a new callable target from the specified rhs and return *this.
template<class FUNC>
function&
operator=(FUNC&& rhs)
requires ! IsReferenceCompatible<typename Decay<FUNC>::type, function>::value
&& IsInvocableWithPrototype<typename Decay<FUNC>::type>::value;
Return Value
reference providing modifiable access to this object
Parameters
Name |
Description |
rhs |
function whose target is copied into this object |
unused |
null pointer literal selecting the empty state |
Created with MrDocs