is_union

Returns True if annotation is a Union.

Signature:

def is_union(annotation: object) -> bool:
...

Parameters:

  1. annotation:

    Type
    object