@@ -6,13 +6,13 @@ Allocating Objects on the Heap
66==============================
77
88
9- .. cfunction :: PyObject* _PyObject_New(PyTypeObject *type)
9+ .. c : function :: PyObject* _PyObject_New (PyTypeObject *type)
1010
1111
12- .. cfunction :: PyVarObject* _PyObject_NewVar(PyTypeObject *type, Py_ssize_t size)
12+ .. c : function :: PyVarObject* _PyObject_NewVar (PyTypeObject *type, Py_ssize_t size)
1313
1414
15- .. cfunction :: PyObject* PyObject_Init(PyObject *op, PyTypeObject *type)
15+ .. c : function :: PyObject* PyObject_Init (PyObject *op, PyTypeObject *type)
1616
1717 Initialize a newly-allocated object *op * with its type and initial
1818 reference. Returns the initialized object. If *type * indicates that the
@@ -21,13 +21,13 @@ Allocating Objects on the Heap
2121 affected.
2222
2323
24- .. cfunction :: PyVarObject* PyObject_InitVar(PyVarObject *op, PyTypeObject *type, Py_ssize_t size)
24+ .. c : function :: PyVarObject* PyObject_InitVar (PyVarObject *op, PyTypeObject *type, Py_ssize_t size)
2525
26- This does everything :cfunc : `PyObject_Init ` does, and also initializes the
26+ This does everything :c:func : `PyObject_Init ` does, and also initializes the
2727 length information for a variable-size object.
2828
2929
30- .. cfunction :: TYPE* PyObject_New(TYPE, PyTypeObject *type)
30+ .. c : function :: TYPE* PyObject_New (TYPE, PyTypeObject *type)
3131
3232 Allocate a new Python object using the C structure type *TYPE * and the
3333 Python type object *type *. Fields not defined by the Python object header
@@ -36,7 +36,7 @@ Allocating Objects on the Heap
3636 the type object.
3737
3838
39- .. cfunction :: TYPE* PyObject_NewVar(TYPE, PyTypeObject *type, Py_ssize_t size)
39+ .. c : function :: TYPE* PyObject_NewVar (TYPE, PyTypeObject *type, Py_ssize_t size)
4040
4141 Allocate a new Python object using the C structure type *TYPE * and the
4242 Python type object *type *. Fields not defined by the Python object header
@@ -48,24 +48,24 @@ Allocating Objects on the Heap
4848 improving the memory management efficiency.
4949
5050
51- .. cfunction :: void PyObject_Del(PyObject *op)
51+ .. c : function :: void PyObject_Del (PyObject *op)
5252
53- Releases memory allocated to an object using :cfunc : `PyObject_New ` or
54- :cfunc : `PyObject_NewVar `. This is normally called from the
53+ Releases memory allocated to an object using :c:func : `PyObject_New ` or
54+ :c:func : `PyObject_NewVar `. This is normally called from the
5555 :attr: `tp_dealloc ` handler specified in the object's type. The fields of
5656 the object should not be accessed after this call as the memory is no
5757 longer a valid Python object.
5858
5959
60- .. cvar :: PyObject _Py_NoneStruct
60+ .. c : var :: PyObject _Py_NoneStruct
6161
6262 Object which is visible in Python as ``None ``. This should only be accessed
63- using the :cmacro : `Py_None ` macro, which evaluates to a pointer to this
63+ using the :c:macro : `Py_None ` macro, which evaluates to a pointer to this
6464 object.
6565
6666
6767.. seealso ::
6868
69- :cfunc : `PyModule_Create `
69+ :c:func : `PyModule_Create `
7070 To allocate and create extension modules.
7171
0 commit comments