add @UnionType handling for return types