[#bsl-vector-0e8-shrink_to_fit]
= xref:bsl.adoc[bsl]::xref:bsl/vector-0e8.adoc[vector&lt;unsigned long&gt;]::shrink&lowbar;to&lowbar;fit
:relfileprefix: ../../
:mrdocs:

Reduce the capacity of this vector to its size&period; If an exception is thrown (other than by the move constructor of a non&hyphen;copy&hyphen;insertable `value&lowbar;type`), `&ast;this` is unaffected&period; Note that this method has no effect if the capacity is equivalent to the size&period;

== Synopsis

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

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
void
shrink&lowbar;to&lowbar;fit();
----


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