[#bsl-basic_string-0fb-erase-05]
= xref:bsl.adoc[bsl]::xref:bsl/basic_string-0fb.adoc[basic&lowbar;string&lt;char&gt;]::erase
:relfileprefix: ../../
:mrdocs:

Erase a character at the specified `position` from this string, and return an iterator providing modifiable access to the character at `position` prior to erasing&period; If no such character exists, return `end()`&period; The behavior is undefined unless `position` is within the half&hyphen;open range `&lsqb;cbegin() &period;&period; cend())&rsqb;`&period;

== Synopsis

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

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
xref:bsl/basic_string-0fb/iterator.adoc[iterator]
erase(xref:bsl/basic_string-0fb/const_iterator.adoc[const&lowbar;iterator] position);
----


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