diff options
| author | Georg Brandl <georg@python.org> | 2010-10-15 16:42:37 +0000 |
|---|---|---|
| committer | Georg Brandl <georg@python.org> | 2010-10-15 16:42:37 +0000 |
| commit | d0b0e1d8690f5c8534e129bac626175f31068b7a (patch) | |
| tree | 539f293bab400cbc15e2499baf58d03dae4916df /Doc | |
| parent | d2413428dcf5b4ad3c5604319f694c36b13e96af (diff) | |
| download | cpython-git-d0b0e1d8690f5c8534e129bac626175f31068b7a.tar.gz | |
#6798: fix wrong docs for the arguments to several trace events.
Diffstat (limited to 'Doc')
| -rw-r--r-- | Doc/c-api/init.rst | 9 | ||||
| -rw-r--r-- | Doc/library/sys.rst | 9 |
2 files changed, 10 insertions, 8 deletions
diff --git a/Doc/c-api/init.rst b/Doc/c-api/init.rst index 031e322f4f..1c621555e2 100644 --- a/Doc/c-api/init.rst +++ b/Doc/c-api/init.rst @@ -929,13 +929,14 @@ Python-level trace functions in previous versions. +------------------------------+--------------------------------------+ | :const:`PyTrace_LINE` | Always *NULL*. | +------------------------------+--------------------------------------+ - | :const:`PyTrace_RETURN` | Value being returned to the caller. | + | :const:`PyTrace_RETURN` | Value being returned to the caller, | + | | or *NULL* if caused by an exception. | +------------------------------+--------------------------------------+ - | :const:`PyTrace_C_CALL` | Name of function being called. | + | :const:`PyTrace_C_CALL` | Function object being called. | +------------------------------+--------------------------------------+ - | :const:`PyTrace_C_EXCEPTION` | Always *NULL*. | + | :const:`PyTrace_C_EXCEPTION` | Function object being called. | +------------------------------+--------------------------------------+ - | :const:`PyTrace_C_RETURN` | Always *NULL*. | + | :const:`PyTrace_C_RETURN` | Function object being called. | +------------------------------+--------------------------------------+ diff --git a/Doc/library/sys.rst b/Doc/library/sys.rst index 352eb62f89..0f35b8b328 100644 --- a/Doc/library/sys.rst +++ b/Doc/library/sys.rst @@ -806,8 +806,9 @@ always available. ``'return'`` A function (or other code block) is about to return. The local trace - function is called; *arg* is the value that will be returned. The trace - function's return value is ignored. + function is called; *arg* is the value that will be returned, or ``None`` + if the event is caused by an exception being raised. The trace function's + return value is ignored. ``'exception'`` An exception has occurred. The local trace function is called; *arg* is a @@ -819,10 +820,10 @@ always available. a built-in. *arg* is the C function object. ``'c_return'`` - A C function has returned. *arg* is ``None``. + A C function has returned. *arg* is the C function object. ``'c_exception'`` - A C function has raised an exception. *arg* is ``None``. + A C function has raised an exception. *arg* is the C function object. Note that as an exception is propagated down the chain of callers, an ``'exception'`` event is generated at each level. |
