Skip to content

Commit

Permalink
Link to Python/errors.c
Browse files Browse the repository at this point in the history
  • Loading branch information
AA-Turner authored Oct 4, 2024
1 parent 235cbe1 commit 326017d
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion InternalDocs/exception_handling.md
Original file line number Diff line number Diff line change
Expand Up @@ -190,5 +190,6 @@ Exception Chaining Implementation
[Exception chaining](https://docs.python.org/dev/tutorial/errors.html#exception-chaining)
refers to setting the ``__context__`` and ``__cause__`` fields of an exception as it is
being raised. The ``__context__`` field is set by ``_PyErr_SetObject()`` in
``Python/errors.c`` (which is ultimately called by all ``PyErr_Set*()`` functions).
[Python/errors.c](https://github.com/python/cpython/blob/main/Python/errors.c)
(which is ultimately called by all ``PyErr_Set*()`` functions).
The ``__cause__`` field (explicit chaining) is set by the ``RAISE_VARARGS`` bytecode.

0 comments on commit 326017d

Please sign in to comment.