def _hastypes(self, expr, types):
        _types = [ cls.__name__ for cls in expr.__class__.mro() ]
        return bool(set(_types).intersection(types))
Check if ``expr`` is any of ``types``.
dataset/ETHPy150Open sympy/sympy/sympy/simplify/epathtools.py/EPath._hastypes