This visitor, when invoked as a non‐modifiable function object on an instance of some template parameter TYPE, will create a default instance of TYPE.

Synopsis

Declared in <bdlb_variant.h>

struct Variant_DefaultConstructVisitor;

Member Functions

Name

Description

Variant_DefaultConstructVisitor [constructor]

Create a default‐construct visitor that uses the specified allocator to supply memory.

operator()

Default‐construct the specified value in place using the allocator supplied at construction of this visitor.

Data Members

Name

Description

d_allocator_p

Allocator used to default‐construct the visited type.

Created with MrDocs