Handle union types for methods and callbacks.