@@ -34,18 +34,20 @@ There are a few functions specific to Python functions.
3434 Return a new function object associated with the code object *code *. *globals *
3535 must be a dictionary with the global variables accessible to the function.
3636
37- The function's docstring and name are retrieved from the code object. *__module__ *
37+ The function's docstring and name are retrieved from the code object.
38+ :func: `~function.__module__ `
3839 is retrieved from *globals *. The argument defaults, annotations and closure are
39- set to ``NULL ``. * __qualname__ * is set to the same value as the code object's
40- :attr: `~codeobject.co_qualname ` field.
40+ set to ``NULL ``. :attr: ` ~function. __qualname__` is set to the same value as
41+ the code object's :attr: `~codeobject.co_qualname ` field.
4142
4243
4344.. c :function :: PyObject* PyFunction_NewWithQualName (PyObject *code, PyObject *globals, PyObject *qualname)
4445
4546 As :c:func: `PyFunction_New `, but also allows setting the function object's
46- ``__qualname__ `` attribute. *qualname * should be a unicode object or ``NULL ``;
47- if ``NULL ``, the ``__qualname__ `` attribute is set to the same value as the
48- code object's :attr: `~codeobject.co_qualname ` field.
47+ :attr: `~function.__qualname__ ` attribute.
48+ *qualname * should be a unicode object or ``NULL ``;
49+ if ``NULL ``, the :attr: `!__qualname__ ` attribute is set to the same value as
50+ the code object's :attr: `~codeobject.co_qualname ` field.
4951
5052 .. versionadded :: 3.3
5153
@@ -62,11 +64,12 @@ There are a few functions specific to Python functions.
6264
6365.. c :function :: PyObject* PyFunction_GetModule (PyObject *op)
6466
65- Return a :term: `borrowed reference ` to the *__module__ * attribute of the
66- function object *op *. It can be *NULL *.
67+ Return a :term: `borrowed reference ` to the :attr: `~function.__module__ `
68+ attribute of the :ref: `function object <user-defined-funcs >` *op *.
69+ It can be *NULL *.
6770
68- This is normally a string containing the module name, but can be set to any
69- other object by Python code.
71+ This is normally a :class: ` string <str> ` containing the module name,
72+ but can be set to any other object by Python code.
7073
7174
7275.. c :function :: PyObject* PyFunction_GetDefaults (PyObject *op)
0 commit comments