Create a Variant_Union object holding the alternative at index (template parameter) t_INDEX.
Synopsis
Declared in <bslstl_variant.h>
template<
size_t t_INDEX,
class... t_ARGS>
Variant_Union(
bsl::in_place_index_t<t_INDEX> inPlaceIndex,
t_ARGS&&... args);
Description
Create a Variant_Union object holding the alternative at index (template parameter) t_INDEX in (template parameters) 't_HEAD, t_TAIL...`, direct‐initialized from the specified args'. Note that `t_INDEX is not necessarily the absolute index of the desired alternative in the bsl::variant object. We use the tag to "unravel" the union until we get to the desired alternative type.
Parameters
Name |
Description |
inPlaceIndex |
tag selecting the alternative at index |
args |
arguments forwarded to the alternative's constructor |
Created with MrDocs