VariantN.get
inout(T) get(T)() @property inoutReturns the value stored in the VariantN object, either by specifying the needed type or the index in the list of allowed types. The latter overload only applies to bounded variants (e.g. Algebraic).
Parameters
T | The requested type. The currently stored value must implicitly convert to the requested type, in fact DecayStaticToDynamicArray!T. If an implicit conversion is not possible, throws a VariantException. |
index | The index of the type among AllowedTypesParam, zero-based. |
@property auto get(uint index)() if (index < AllowedTypes.length) inoutDitto