summaryrefslogtreecommitdiffstats
path: root/Doc/c-api
diff options
context:
space:
mode:
Diffstat (limited to 'Doc/c-api')
-rw-r--r--Doc/c-api/number.rst2
-rw-r--r--Doc/c-api/object.rst2
2 files changed, 2 insertions, 2 deletions
diff --git a/Doc/c-api/number.rst b/Doc/c-api/number.rst
index 1bf08ad..bb72119 100644
--- a/Doc/c-api/number.rst
+++ b/Doc/c-api/number.rst
@@ -256,7 +256,7 @@ Number Protocol
.. cfunction:: PyObject* PyNumber_Index(PyObject *o)
Returns the *o* converted to a Python int or long on success or *NULL* with a
- TypeError exception raised on failure.
+ :exc:`TypeError` exception raised on failure.
.. cfunction:: PyObject* PyNumber_ToBase(PyObject *n, int base)
diff --git a/Doc/c-api/object.rst b/Doc/c-api/object.rst
index 7b9682c..bf2f484 100644
--- a/Doc/c-api/object.rst
+++ b/Doc/c-api/object.rst
@@ -257,7 +257,7 @@ is considered sufficient for this determination.
.. cfunction:: long PyObject_HashNotImplemented(PyObject *o)
- Set a TypeError indicating that ``type(o)`` is not hashable and return ``-1``.
+ Set a :exc:`TypeError` indicating that ``type(o)`` is not hashable and return ``-1``.
This function receives special treatment when stored in a ``tp_hash`` slot,
allowing a type to explicitly indicate to the interpreter that it is not
hashable.