The copy constructor of type
vector<vector<int>
has linear complexity,
even though the complexity of copying each contained
vector<int>
is itself linear.
Allocator-aware containers ([container.alloc.reqmts])
other than basic_string construct elements using the function
allocator_traits<allocator_type>::rebind_traits<U>::construct
and destroy elements using the function
allocator_traits<allocator_type>::rebind_traits<U>::destroy ([allocator.traits.members]),
where U is either allocator_type::value_type or
an internal type used by the container.
These functions are called only for the
container's element type, not for internal types used by the container.
This
means, for example, that a node-based container would need to construct nodes containing
aligned buffers and call construct to place the element into the buffer.
The following exposition-only concept is used in the definition of containers:
template<class R, class T>conceptcontainer-compatible-range=/ exposition only
ranges::input_range<R>&&convertible_to<ranges::range_reference_t<R>, T>;