Merged revisions 76923,76926,77009,77082-77083,77085,77087,77121 via svnmerge from
svn+ssh://svn.python.org/python/branches/py3k
................
r76923 | georg.brandl | 2009-12-20 15:24:06 +0100 (So, 20 Dez 2009) | 1 line
#7493: more review fixes.
................
r76926 | georg.brandl | 2009-12-20 15:38:23 +0100 (So, 20 Dez 2009) | 9 lines
Recorded merge of revisions 76925 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk
........
r76925 | georg.brandl | 2009-12-20 15:33:20 +0100 (So, 20 Dez 2009) | 1 line
#7381: subprocess documentation and library docstring consistency fixes.
........
................
r77009 | georg.brandl | 2009-12-23 11:30:45 +0100 (Mi, 23 Dez 2009) | 1 line
#7417: add signature to open() docstring.
................
r77082 | georg.brandl | 2009-12-28 08:59:20 +0100 (Mo, 28 Dez 2009) | 1 line
#7577: fix signature info for getbufferproc.
................
r77083 | georg.brandl | 2009-12-28 09:00:47 +0100 (Mo, 28 Dez 2009) | 9 lines
Merged revisions 77081 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk
........
r77081 | georg.brandl | 2009-12-28 08:59:05 +0100 (Mo, 28 Dez 2009) | 1 line
#7577: fix signature of PyBuffer_FillInfo().
........
................
r77085 | georg.brandl | 2009-12-28 09:02:38 +0100 (Mo, 28 Dez 2009) | 9 lines
Merged revisions 77084 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk
........
r77084 | georg.brandl | 2009-12-28 09:01:59 +0100 (Mo, 28 Dez 2009) | 1 line
#7586: fix typo.
........
................
r77087 | georg.brandl | 2009-12-28 09:10:38 +0100 (Mo, 28 Dez 2009) | 9 lines
Recorded merge of revisions 77086 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk
........
r77086 | georg.brandl | 2009-12-28 09:09:32 +0100 (Mo, 28 Dez 2009) | 1 line
#7381: consistency update, and backport avoiding ``None >= 0`` check from py3k.
........
................
r77121 | georg.brandl | 2009-12-29 22:38:35 +0100 (Di, 29 Dez 2009) | 1 line
#7590: exception classes no longer are in the "exceptions" module. Also clean up text that was written with string exceptions in mind.
................
diff --git a/Doc/library/exceptions.rst b/Doc/library/exceptions.rst
index ceebf5e..b53f670 100644
--- a/Doc/library/exceptions.rst
+++ b/Doc/library/exceptions.rst
@@ -3,20 +3,12 @@
Built-in Exceptions
===================
-.. module:: exceptions
- :synopsis: Standard exception classes.
-
-
-Exceptions should be class objects. The exceptions are defined in the module
-:mod:`exceptions`. This module never needs to be imported explicitly: the
-exceptions are provided in the built-in namespace as well as the
-:mod:`exceptions` module.
-
.. index::
statement: try
statement: except
-For class exceptions, in a :keyword:`try` statement with an :keyword:`except`
+In Python, all exceptions must be instances of a class that derives from
+:class:`BaseException`. In a :keyword:`try` statement with an :keyword:`except`
clause that mentions a particular class, that clause also handles any exception
classes derived from that class (but not exception classes from which *it* is
derived). Two exception classes that are not related via subclassing are never
@@ -44,7 +36,7 @@
defining exceptions is available in the Python Tutorial under
:ref:`tut-userexceptions`.
-The following exceptions are only used as base classes for other exceptions.
+The following exceptions are used mostly as base classes for other exceptions.
.. XXX document with_traceback()
@@ -99,8 +91,8 @@
In this last case, :attr:`args` contains the verbatim constructor arguments as a
tuple.
-The following exceptions are the exceptions that are actually raised.
+The following exceptions are the exceptions that are usually raised.
.. exception:: AssertionError
@@ -369,10 +361,10 @@
associated value is a string indicating the type of the operands and the
operation.
+
The following exceptions are used as warning categories; see the :mod:`warnings`
module for more information.
-
.. exception:: Warning
Base class for warning categories.