mirror of
https://github.com/python/cpython.git
synced 2025-09-26 18:29:57 +00:00
The sequence behavior is now on the Exception root class rather than
on the StandardError class.
This commit is contained in:
parent
fdacc58bfe
commit
6cd7ecb10b
2 changed files with 8 additions and 6 deletions
|
@ -62,14 +62,15 @@ from this class. All user-defined exceptions should also be derived
|
||||||
from this class, but this is not (yet) enforced. The \code{str()}
|
from this class, but this is not (yet) enforced. The \code{str()}
|
||||||
function, when applied to an instance of this class (or most derived
|
function, when applied to an instance of this class (or most derived
|
||||||
classes) returns the string value of the argument or arguments, or an
|
classes) returns the string value of the argument or arguments, or an
|
||||||
empty string if no arguments were given to the constructor.
|
empty string if no arguments were given to the constructor. When used
|
||||||
|
as a sequence, this accesses the arguments given to the constructor
|
||||||
|
(handy for backward compatibility with old code).
|
||||||
\end{excdesc}
|
\end{excdesc}
|
||||||
|
|
||||||
\begin{excdesc}{StandardError}
|
\begin{excdesc}{StandardError}
|
||||||
The base class for built-in exceptions. All built-in exceptions are
|
The base class for built-in exceptions. All built-in exceptions are
|
||||||
derived from this class, which is itself derived from the root class
|
derived from this class, which is itself derived from the root class
|
||||||
\code{Exception}. For backward compatibility, when used as a
|
\code{Exception}.
|
||||||
sequence, this accesses the arguments given to the constructor.
|
|
||||||
\end{excdesc}
|
\end{excdesc}
|
||||||
|
|
||||||
\begin{excdesc}{ArithmeticError}
|
\begin{excdesc}{ArithmeticError}
|
||||||
|
|
|
@ -62,14 +62,15 @@ from this class. All user-defined exceptions should also be derived
|
||||||
from this class, but this is not (yet) enforced. The \code{str()}
|
from this class, but this is not (yet) enforced. The \code{str()}
|
||||||
function, when applied to an instance of this class (or most derived
|
function, when applied to an instance of this class (or most derived
|
||||||
classes) returns the string value of the argument or arguments, or an
|
classes) returns the string value of the argument or arguments, or an
|
||||||
empty string if no arguments were given to the constructor.
|
empty string if no arguments were given to the constructor. When used
|
||||||
|
as a sequence, this accesses the arguments given to the constructor
|
||||||
|
(handy for backward compatibility with old code).
|
||||||
\end{excdesc}
|
\end{excdesc}
|
||||||
|
|
||||||
\begin{excdesc}{StandardError}
|
\begin{excdesc}{StandardError}
|
||||||
The base class for built-in exceptions. All built-in exceptions are
|
The base class for built-in exceptions. All built-in exceptions are
|
||||||
derived from this class, which is itself derived from the root class
|
derived from this class, which is itself derived from the root class
|
||||||
\code{Exception}. For backward compatibility, when used as a
|
\code{Exception}.
|
||||||
sequence, this accesses the arguments given to the constructor.
|
|
||||||
\end{excdesc}
|
\end{excdesc}
|
||||||
|
|
||||||
\begin{excdesc}{ArithmeticError}
|
\begin{excdesc}{ArithmeticError}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue