type(X) is Y  ->  isinstance(X, Y)

Modulo `not`s.