This struct provides a helper for implementing Variant::applyRaw that enables applyRaw to support visitor functors that do not provide an overload for operator()(bslmf::Nil). Objects of this type are constructed using a functor of (template parameter) type VISITOR, whose operator() returns the (template parameter) type RESULT_TYPE. A Variant_RawVisitorHelper wraps a functor of type VISITOR and provides an implementation of operator()(bslmf::Nil) that performs a BSLS_ASSERT_OPT(false). Note that this overload is needed to enable compilation (specifically, to instantiate doApply and doApplyR), but is never invoked by any code path at runtime.
Declared in <bdlb_variant.h>
template<
class RESULT_TYPE,
class VISITOR>
class Variant_RawVisitorHelper;
| Name | Description |
|---|---|
Variant_RawVisitorHelper [constructor] | Create a RawVisitorHelper functor that delegates to the specified visitor. |
operator() | Function call operators |