def _clone_op_compare(fn):

    @functools.wraps(fn)
    def cmp(self: '_CloneOp', other: '_CloneOp'):
        assert isinstance(other, _CloneOp)
        assert (self.ref.extent is other.ref.extent)
        assert tuple.__ne__(self, other)
        return fn(_clone_op_compare_key(self), _clone_op_compare_key(other))
    return cmp
def _clone_op_compare(fn):

    @functools.wraps(fn)
    def cmp(self: '_CloneOp', other: '_CloneOp'):
        assert isinstance(other, _CloneOp)
        assert (self.ref.extent is other.ref.extent)
        assert tuple.__ne__(self, other)
        return fn(_clone_op_compare_key(self), _clone_op_compare_key(other))
    return cmp