

def not_(self, other):
    "Negate a ternary value.\n\n        (Python doesn't allow useful overriding of ``not``.)\n\n        "
    if (other is self):
        return other
    elif (other is True):
        return False
    elif (other is False):
        return True
    else:
        raise TypeError(type(other).__name__)

dataset/ETHPy150Open jek/flatland/flatland/util/base.py Maybe.not_/original