def next(itr, default=_undef):
        if default is _undef:
            return itr.next()
        try:
            return itr.next()
        except StopIteration:
            return default
compat wrapper for next()
dataset/ETHPy150Open twisted/ldaptor/ldaptor/compat.py/next