Use the allocator's nested is_always_equal when defined.

Synopsis

Declared in <bslma_allocatortraits.h>

template<
    class ALLOC,
    bool = AllocatorTraits_HasIsAlwaysEqual<ALLOC>::value>
struct AllocatorTraits_IsAlwaysEqual
    : ALLOC::is_always_equal

Description

This struct template sets the boolean type for the attribute named is_always_equal to the nested type alias in the given (template parameter) ALLOC if ALLOC defines such an alias (i.e., if true == AllocatorTraits_HasIsAlwaysEqual<ALLOCATOR_TYPE>::value).

Base Classes

Name

Description

ALLOC::is_always_equal

Specializations

Name

Description

AllocatorTraits_IsAlwaysEqual<ALLOC, false>

Sets is_always_equal to bsl::is_empty<ALLOC> when not defined by ALLOC.

Created with MrDocs