std::any::emplace

std::any::emplace

template< class ValueType, class... Args >
std::decay_t<ValueType>& emplace( Args&&... args );
(1) (since C++17)
template< class ValueType, class U, class... Args >
std::decay_t<ValueType>& emplace( std::initializer_list<U> il, Args&&... args );
(2) (since C++17)

Changes the contained object to one of type std::decay_t<ValueType> constructed from the arguments.