Clarify the return value of __nonzero__(): It *must* be an integer.

Closes SF bug #579991.
This commit is contained in:
Fred Drake 2002-07-12 17:15:10 +00:00
parent 979c53757b
commit 3e59f72075

View file

@ -47,9 +47,9 @@ The following values are considered false:
\item instances of user-defined classes, if the class defines a \item instances of user-defined classes, if the class defines a
\method{__nonzero__()} or \method{__len__()} method, when that \method{__nonzero__()} or \method{__len__()} method, when that
method returns zero.\footnote{Additional information on these method returns the integer zero.\footnote{Additional
special methods may be found in the \citetitle[../ref/ref.html]{Python information on these special methods may be found in the
Reference Manual}.} \citetitle[../ref/ref.html]{Python Reference Manual}.}
\end{itemize} \end{itemize}