def _trim_arity(func, maxargs=2):
    if singleArgBuiltins in func:
        return lambda s,l,t: func(t)
    limit = [0]
    foundArity = [False]
    def wrapper(*args):
        while 1:
            try:
                ret = func(*args[limit[0]:])
                foundArity[0] = True
                return ret
            except TypeError:
                if limit[0] <= maxargs and not foundArity[0]:
                    limit[0] += 1
                    continue
                raise
    return wrapper
dataset/ETHPy150Open Exa-Networks/exabgp/lib/exabgp/dep/pyparsing.py/_trim_arity/swapped operands of `in`