In the
range version (1), the new contents are elements constructed from each of the elements in the range between
first and
last, in the same order.
In the
fill version (2), the new contents are
n elements, each initialized to a copy of
val.
If a reallocation happens,the storage needed is allocated using the
internal allocator.
In the
range version (1), the new contents are elements constructed from each of the elements in the range between
first and
last, in the same order.
In the
fill version (2), the new contents are
n elements, each initialized to a copy of
val.
In the
initializer list version (3), the new contents are copies of the values passed as initializer list, in the same order.
The
internal allocator is used (through its
traits) to
allocate and
deallocate storage if a reallocation happens. It is also used to
destroy all existing elements, and to
construct the new ones.