Skip to content

Commit fa59bda

Browse files
authored
gh-93738: Documentation C syntax (:c:data:view->obj -> :c:expr:view->obj) (#97773)
:c:data:`view->obj` -> :c:expr:`view->obj`
1 parent a77d9de commit fa59bda

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

Doc/c-api/typeobj.rst

+5-5
Original file line numberDiff line numberDiff line change
@@ -2356,24 +2356,24 @@ Buffer Object Structures
23562356
steps:
23572357

23582358
(1) Check if the request can be met. If not, raise :c:data:`PyExc_BufferError`,
2359-
set :c:data:`view->obj` to ``NULL`` and return ``-1``.
2359+
set :c:expr:`view->obj` to ``NULL`` and return ``-1``.
23602360

23612361
(2) Fill in the requested fields.
23622362

23632363
(3) Increment an internal counter for the number of exports.
23642364

2365-
(4) Set :c:data:`view->obj` to *exporter* and increment :c:data:`view->obj`.
2365+
(4) Set :c:expr:`view->obj` to *exporter* and increment :c:expr:`view->obj`.
23662366

23672367
(5) Return ``0``.
23682368

23692369
If *exporter* is part of a chain or tree of buffer providers, two main
23702370
schemes can be used:
23712371

23722372
* Re-export: Each member of the tree acts as the exporting object and
2373-
sets :c:data:`view->obj` to a new reference to itself.
2373+
sets :c:expr:`view->obj` to a new reference to itself.
23742374

23752375
* Redirect: The buffer request is redirected to the root object of the
2376-
tree. Here, :c:data:`view->obj` will be a new reference to the root
2376+
tree. Here, :c:expr:`view->obj` will be a new reference to the root
23772377
object.
23782378

23792379
The individual fields of *view* are described in section
@@ -2415,7 +2415,7 @@ Buffer Object Structures
24152415
*view* argument.
24162416

24172417

2418-
This function MUST NOT decrement :c:data:`view->obj`, since that is
2418+
This function MUST NOT decrement :c:expr:`view->obj`, since that is
24192419
done automatically in :c:func:`PyBuffer_Release` (this scheme is
24202420
useful for breaking reference cycles).
24212421

0 commit comments

Comments
 (0)