Destroy the current target (if any) of this object, then set the target to the specified rhs wrapper containing a reference to a callable object and return *this. The result is equivalent to having constructed *this from rhs and this‐>get_allocator(). Note that this assignment is a separate overload only because it is unconditionally noexcept.

Synopsis

Declared in <bslstl_function.h>

template<class FUNC>
function&
operator=(bsl::reference_wrapper<FUNC> rhs) noexcept
requires IsInvocableWithPrototype<typename Decay<FUNC>::type>::value;

Created with MrDocs