[#bsl-variant_alternative-06]
= xref:bsl.adoc[bsl]::xref:bsl/variant_alternative-0c.adoc[variant&lowbar;alternative]&lt;t&lowbar;INDEX, xref:bsl/variant.adoc[variant&lt;t&lowbar;HEAD, t&lowbar;TAIL&period;&period;&period;&gt;]&gt;
:relfileprefix: ../
:mrdocs:

Compute the alternative type at index `t&lowbar;INDEX` of a `bsl&colon;&colon;variant`&period;

== Synopsis

Declared in `&lt;bslstl&lowbar;variant&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
template&lt;
    std::size&lowbar;t t&lowbar;INDEX,
    class t&lowbar;HEAD,
    class&period;&period;&period; t&lowbar;TAIL&gt;
struct xref:bsl/variant_alternative-0c.adoc[variant&lowbar;alternative]&lt;t&lowbar;INDEX, xref:bsl/variant.adoc[variant&lt;t&lowbar;HEAD, t&lowbar;TAIL&period;&period;&period;&gt;]&gt;
    : xref:bsl/Variant_VariantAlternativeImpl-06e.adoc[Variant&lowbar;VariantAlternativeImpl&lt;t&lowbar;INDEX, t&lowbar;HEAD, t&lowbar;TAIL&period;&period;&period;&gt;]
----

== Description

This partial specialization of `variant&lowbar;alternative` computes the alternative type at index `t&lowbar;INDEX` for a `bsl&colon;&colon;variant` specialized on (template parameters) `t&lowbar;HEAD, t&lowbar;TAIL&period;&period;&period;`&period;

`t&lowbar;INDEX` shall be a valid alternative index for the variant&period;

== Base Classes

[cols="1,4"]
|===
| Name| Description
| `xref:bsl/Variant_VariantAlternativeImpl-06e.adoc[Variant&lowbar;VariantAlternativeImpl&lt;t&lowbar;INDEX, t&lowbar;HEAD, t&lowbar;TAIL&period;&period;&period;&gt;]`
| This component&hyphen;private metafunction provides the implementation of `bsl&colon;&colon;variant&lowbar;alternative`&period;
|===


[.small]#Created with https://www.mrdocs.com[MrDocs]#
