BSLSTL_VARIANT_INDEX_OF

Compute the index of the first alternative identical to TYPE.

Synopsis

Declared in <bslstl_variant.h>

#define BSLSTL_VARIANT_INDEX_OF(TYPE, VARIANT)

Description

This component-private macro expands to the index of the first alternative in the specified VARIANT that is identical to the specified TYPE, or bsl::variant_npos if no such alternative exists.

Parameters

NameDescription
TYPEcandidate alternative type
VARIANTvariant specialization to search