summaryrefslogtreecommitdiffstats
path: root/Doc/c-api/buffer.rst
diff options
context:
space:
mode:
Diffstat (limited to 'Doc/c-api/buffer.rst')
-rw-r--r--Doc/c-api/buffer.rst12
1 files changed, 7 insertions, 5 deletions
diff --git a/Doc/c-api/buffer.rst b/Doc/c-api/buffer.rst
index d98ece3..740b575 100644
--- a/Doc/c-api/buffer.rst
+++ b/Doc/c-api/buffer.rst
@@ -1,5 +1,10 @@
.. highlightlang:: c
+.. index::
+ single: buffer protocol
+ single: buffer interface; (see buffer protocol)
+ single: buffer object; (see buffer protocol)
+
.. _bufferobjects:
Buffer Protocol
@@ -9,9 +14,6 @@ Buffer Protocol
.. sectionauthor:: Benjamin Peterson
-.. index::
- single: buffer interface
-
Certain objects available in Python wrap access to an underlying memory
array or *buffer*. Such objects include the built-in :class:`bytes` and
:class:`bytearray`, and some extension types like :class:`array.array`.
@@ -23,8 +25,8 @@ characteristic of being backed by a possibly large memory buffer. It is
then desireable, in some situations, to access that buffer directly and
without intermediate copying.
-Python provides such a facility at the C level in the form of the *buffer
-protocol*. This protocol has two sides:
+Python provides such a facility at the C level in the form of the :ref:`buffer
+protocol <bufferobjects>`. This protocol has two sides:
.. index:: single: PyBufferProcs