]> granicus.if.org Git - python/commitdiff
Add version added info for with statement and context managers
authorNeal Norwitz <nnorwitz@gmail.com>
Tue, 28 Mar 2006 05:51:02 +0000 (05:51 +0000)
committerNeal Norwitz <nnorwitz@gmail.com>
Tue, 28 Mar 2006 05:51:02 +0000 (05:51 +0000)
Doc/lib/libcontextlib.tex
Doc/ref/ref3.tex
Doc/ref/ref7.tex

index 842c95492b0839a8944d8e012bb4a703e248319f..46f9cddafe91855298e32db490b395e4d156fe83 100644 (file)
@@ -4,6 +4,8 @@
 \declaremodule{standard}{contextlib}
 \modulesynopsis{Utilities for \keyword{with}-statement contexts.}
 
+\versionadded{2.5}
+
 This module provides utilities for common tasks involving the
 \keyword{with} statement.
 
index dfd41029a1837ef700728439c6f932de18bd2f53..48a37f191dd8a3c2eebdf0aa7973729db27d2582 100644 (file)
@@ -2109,6 +2109,8 @@ implement a \method{__coerce__()} method, for use by the built-in
 
 \subsection{Context Managers and Contexts\label{context-managers}}
 
+\versionadded{2.5}
+
 A \dfn{context manager} is an object that manages the entry to, and exit
 from, a \dfn{context} surrounding a block of code.  Context managers are
 normally invoked using the \keyword{with} statement (described in
index a5a6eafcc597c40ef76a3a74174e594cdc595177..ecbc75614a9aac9fc6f93947b2026e21bb803876 100644 (file)
@@ -312,6 +312,8 @@ statement to generate exceptions may be found in section~\ref{raise}.
 \section{The \keyword{with} statement\label{with}}
 \stindex{with}
 
+\versionadded{2.5}
+
 The \keyword{with} statement is used to wrap the execution of a block
 with methods defined by a context manager (see
 section~\ref{context-managers}). This allows common