[#BloombergLP-bdlb-VariantImp_AllocatorBase-2constructor-0d]
= xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/bdlb.adoc[bdlb]::xref:BloombergLP/bdlb/VariantImp_AllocatorBase.adoc[VariantImp&lowbar;AllocatorBase]::VariantImp&lowbar;AllocatorBase
:relfileprefix: ../../../
:mrdocs:

Create an allocator&hyphen;aware base with the given type index&period;

== Synopsis

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

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
VariantImp&lowbar;AllocatorBase(
    int type,
    xref:BloombergLP/bslma/Allocator.adoc[bslma::Allocator]* basicAllocator,
    xref:bsl/true_type.adoc[bsl::true&lowbar;type] tag);
----

== Description

Create a `VariantImp&lowbar;AllocatorBase` with the specified `type` indicating the type of the object that the variant will initially hold, and the specified `basicAllocator` to supply memory&period;

== Parameters

[cols="1,4"]
|===
| Name| Description
| *type*
| type index of the initially held alternative
| *basicAllocator*
| allocator used to supply memory
| *tag*
| unused overload&hyphen;resolution tag
|===


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