Union.as

T as(T)() @trusted nothrow @nogc ref

Returns the data of the given type. Will assert if the type is not the same as the currently active type.