Return the allocator to use when copy‐constructing a container.
Synopsis
Declared in <bslstp_util.h>
template<class ALLOCATOR>
static
ALLOCATOR
copyContainerAllocator(ALLOCATOR const& rhsAlloc);
Description
rhsAlloc is intended to be the allocator from the container being copied. If the ALLOCATOR type uses bslma allocator semantics, then ignore rhsAlloc and return the default allocator. Otherwise, return rhsAlloc unchanged.
Return Value
default allocator if ALLOCATOR uses bslma semantics; otherwise rhsAlloc unchanged
Parameters
Name |
Description |
rhsAlloc |
allocator from the container being copied |
Created with MrDocs