Organizing union type members as subclasses