def __eq__(s, t):
        ttype = type(t)
        if ttype is mpq:
            return s._mpq_ == t._mpq_
        if int_types in ttype:
            a, b = s._mpq_
            if b != 1:
                return False
            return a == t
        return NotImplemented
dataset/ETHPy150Open fredrik-johansson/mpmath/mpmath/rational.py/mpq.__eq__/swapped operands of `in`