Mercurial > cpython-lru_cache-weakref
diff Doc/lib/libstdtypes.tex @ 24631:110c6edaf62f legacy-trunk
Clarify that the bool instances are acceptable return values from
__nonzero__(), in response to SF bug #579991.
| author | Fred Drake <fdrake@acm.org> |
|---|---|
| date | Wed, 07 Aug 2002 15:40:15 +0000 |
| parents | d7ca0a2ce074 |
| children | f57d6db423f2 |
line wrap: on
line diff
--- a/Doc/lib/libstdtypes.tex Wed Aug 07 15:18:57 2002 +0000 +++ b/Doc/lib/libstdtypes.tex Wed Aug 07 15:40:15 2002 +0000 @@ -33,10 +33,10 @@ \begin{itemize} \item \code{None} - \withsubitem{(Built-in object)}{\ttindex{None}} + \withsubitem{(Built-in object)}{\ttindex{None}} \item \code{False} - \withsubitem{(Built-in object)}{\ttindex{False}} + \withsubitem{(Built-in object)}{\ttindex{False}} \item zero of any numeric type, for example, \code{0}, \code{0L}, \code{0.0}, \code{0j}. @@ -46,8 +46,9 @@ \item any empty mapping, for example, \code{\{\}}. \item instances of user-defined classes, if the class defines a - \method{__nonzero__()} or \method{__len__()} method, when that - method returns the integer zero.\footnote{Additional + \method{__nonzero__()} or \method{__len__()} method, when that + method returns the integer zero or \class{bool} value + \code{False}.\footnote{Additional information on these special methods may be found in the \citetitle[../ref/ref.html]{Python Reference Manual}.}
