From: Andrew M. Kuchling Date: Sun, 20 Mar 2005 19:52:18 +0000 (+0000) Subject: Add item X-Git-Tag: v2.5a0~1908 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=511a3a81744e6528e3294267e294e79bee5778d8;p=thirdparty%2FPython%2Fcpython.git Add item --- diff --git a/Doc/whatsnew/whatsnew25.tex b/Doc/whatsnew/whatsnew25.tex index 3d5a32af59de..1a82844e5c80 100644 --- a/Doc/whatsnew/whatsnew25.tex +++ b/Doc/whatsnew/whatsnew25.tex @@ -120,7 +120,17 @@ Example: (Contributed by Raymond Hettinger.) -% itertools.islice() now accepts None for the start and step arguments. +\item The \function{itertools.islice()} function now accepts +\code{None} for the start and step arguments. This makes it more +compatible with the attributes of slice objects, so that you can now write +the following: + +\begin{verbatim} +s = slice(5) # Create slice object +itertools.islice(iterable, s.start, s.stop, s.step) +\end{verbatim} + +(Contributed by Raymond Hettinger.) \item New module: \module{spwd} provides functions for accessing the shadow password database on systems that support it.