[#bsl-list-054-erase-0e] = xref:bsl.adoc[bsl]::xref:bsl/list-054.adoc[list]::erase :relfileprefix: ../../ :mrdocs: `erase` overloads == Synopses Declared in `<bslstl_list.h>` Remove the element at `position` and return an iterator to the next. [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- xref:bsl/list-054/iterator.adoc[list<VALUE, ALLOCATOR>::iterator] xref:bsl/list-054/erase-02.adoc[erase](xref:bsl/list-054/const_iterator.adoc[const_iterator] position); ---- [.small]#xref:bsl/list-054/erase-02.adoc[_» more..._]# Remove the elements in the half‐open range `[dstBegin .. dstEnd)]`. [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- xref:bsl/list-054/iterator.adoc[list<VALUE, ALLOCATOR>::iterator] xref:bsl/list-054/erase-07.adoc[erase]( xref:bsl/list-054/const_iterator.adoc[const_iterator] dstBegin, xref:bsl/list-054/const_iterator.adoc[const_iterator] dstEnd); ---- [.small]#xref:bsl/list-054/erase-07.adoc[_» more..._]# == Return Value * iterator to the element following the erased element * iterator to the element following the last erased element == Parameters [cols="1,4"] |=== | Name| Description | *position* | iterator to the element to remove | *dstBegin* | iterator to the first element to remove | *dstEnd* | iterator past the last element to remove |=== [.small]#Created with https://www.mrdocs.com[MrDocs]#