bsl::list::insert

Insert at the specified dstPosition in this list a copy of the specified value, and return an iterator providing modifiable access to the newly inserted element. This method offers full guarantee of rollback in case an exception is thrown other than by the VALUE copy constructor or assignment operator. This method requires that the (template parameter) VALUE be copy-insertable into this list (see {Requirements on VALUE}). The behavior is undefined unless dstPosition is an iterator in the range [cbegin() .. cend()]endpoints included).

Synopsis

Declared in <bslstl_list.h>

list<VALUE, ALLOCATOR>::iterator
insert(
    const_iterator dstPosition,
    value_type const& value);