title: Why did Python 2.6 add a global next() function?
body: <p>I noticed that Python2.6 added a next() to it's <a href="http://docs.python.org/library/functions.html" rel="nofollow noreferrer">list of global functions</a>.</p>
  
  <blockquote>
    <p><a href="http://docs.python.org/library/functions.html#next" rel="nofollow noreferrer"><code>next(iterator[, default])</code></a></p>
  
  <pre><code>Retrieve the next item from the iterator by calling its next() method.
  </code></pre>
    
    <p>If <code>default</code> is given, it is returned if
    the iterator is exhausted, otherwise
    <code>StopIteration</code> is raised.</p>
  </blockquote>
  
  <p>What was the motivation for adding this?
  What can you do with <code>next(iterator)</code> that you can't do with <code>iterator.next()</code> and an <code>except</code> clause to handle the StopIteration?</p>