Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions Doc/c-api/memoryview.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,12 @@

.. _memoryview-objects:

.. index::

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Quoting the Sphinx documentation:

Since index directives generate cross-reference targets at their location in the source, it makes sense to put them before the thing they refer to – e.g. a heading

As such I'm not sure about this change, the missing anchor should be fixed upstream instead. Possibly something to do with the reference label messing with the anchor? I suggest you open an issue in sphinx-doc/sphinx repository.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Every other adjacent file I looked in has it heading then index so I thought that was the convention here

pair: object; memoryview

MemoryView objects
------------------

.. index::
pair: object; memoryview

A :class:`memoryview` object exposes the C level :ref:`buffer interface
<bufferobjects>` as a Python object which can then be passed around like
any other object.
Expand Down
12 changes: 6 additions & 6 deletions Doc/reference/expressions.rst
Original file line number Diff line number Diff line change
Expand Up @@ -136,13 +136,13 @@ exception.

.. _private-name-mangling:

Private name mangling
^^^^^^^^^^^^^^^^^^^^^

.. index::
pair: name; mangling
pair: private; names

Private name mangling
^^^^^^^^^^^^^^^^^^^^^

When an identifier that textually occurs in a class definition begins with two
or more underscore characters and does not end in two or more underscores, it
is considered a :dfn:`private name` of that class.
Expand Down Expand Up @@ -2669,13 +2669,13 @@ expression. (To create an empty tuple, use an empty pair of parentheses:

.. _iterable-unpacking:

Iterable unpacking
------------------

.. index::
pair: iterable; unpacking
single: * (asterisk); in expression lists

Iterable unpacking
------------------

In an expression list or tuple, list or set display, any expression
may be prefixed with an asterisk (``*``).
This denotes :dfn:`iterable unpacking`.
Expand Down
Loading