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

Change the size of this deque to the specified `newSize`&period; Erase `size() &hyphen; newSize` elements at the back if `newSize &lt; size()`&period; Append `newSize &hyphen; size()` elements at the back having the optionally specified `value` if `newSize &gt; size()`&semi; if `value` is not specified, value&hyphen;initialized objects of the (template parameter) `VALUE&lowbar;TYPE` are emplaced&period; This method has no effect if `newSize &equals;&equals; size()`&period; Throw `bsl&colon;&colon;length&lowbar;error` if `newSize &gt; max&lowbar;size()`&period;

== Synopsis

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

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
void
resize(xref:bsl/deque-0c/size_type.adoc[size&lowbar;type] newSize);
----


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