[#bsl-deque-0c-resize-04] = xref:bsl.adoc[bsl]::xref:bsl/deque-0c.adoc[deque]::resize :relfileprefix: ../../ :mrdocs: `resize` overloads == Synopses Declared in `<bslstl_deque.h>` Change the size of this deque to the specified `newSize`. Erase `size() ‐ newSize` elements at the back if `newSize < size()`. Append `newSize ‐ size()` elements at the back having the optionally specified `value` if `newSize > size()`; if `value` is not specified, value‐initialized objects of the (template parameter) `VALUE_TYPE` are emplaced. This method has no effect if `newSize == size()`. Throw `bsl::length_error` if `newSize > max_size()`. [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- void xref:bsl/deque-0c/resize-02.adoc[resize](xref:bsl/deque-0c/size_type.adoc[size_type] newSize); ---- [.small]#xref:bsl/deque-0c/resize-02.adoc[_» more..._]# Change the size of this deque to the specified `newSize`, inserting `newSize ‐ size()` copies of the specified `value` at the back if `newSize > size()`. If `newSize < size()`, the elements at the back are erased, `value` is ignored, and this method does not throw. If `newSize > size()` and an exception is thrown, `*this` is unaffected. Throw `bsl::length_error` if `newSize > max_size()`. [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- void xref:bsl/deque-0c/resize-01.adoc[resize]( xref:bsl/deque-0c/size_type.adoc[size_type] newSize, VALUE_TYPE const& value); ---- [.small]#xref:bsl/deque-0c/resize-01.adoc[_» more..._]# [.small]#Created with https://www.mrdocs.com[MrDocs]#