[#bsl-deque-0c-erase-03]
= xref:bsl.adoc[bsl]::xref:bsl/deque-0c.adoc[deque]::erase
:relfileprefix: ../../
:mrdocs:

Erase the element at `position` from this deque&period;

== Synopsis

Declared in `&lt;bslstl&lowbar;deque&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
xref:bsl/deque-0c/iterator-02.adoc[deque&lt;VALUE&lowbar;TYPE, ALLOCATOR&gt;::iterator]
erase(xref:bsl/deque-0c/const_iterator.adoc[const&lowbar;iterator] position);
----

== Description

Remove from this deque the element at the specified `position`, and return an iterator providing modifiable access to the element immediately following the removed element, or the position returned by the method `end` if the removed element was the last in the sequence&period; The behavior is undefined unless `position` is an iterator in the range `&lsqb;cbegin() &period;&period; cend())&rsqb;`&period;

== Return Value

iterator to the element following the erased element

== Parameters

[cols="1,4"]
|===
| Name| Description
| *position*
| iterator to the element to erase
|===


[.small]#Created with https://www.mrdocs.com[MrDocs]#
