bpo-38557: Improve documentation for list and tuple C API.#16925
bpo-38557: Improve documentation for list and tuple C API.#16925serhiy-storchaka merged 1 commit intopython:masterfrom
Conversation
terryjreedy
left a comment
There was a problem hiding this comment.
I assume that the re-wordings and additions are technically correct. They otherwise look good to me.
| and *high*. Return *NULL* and set an exception if unsuccessful. Analogous | ||
| to ``list[low:high]``. Negative indices, as when slicing from Python, are not | ||
| supported. | ||
| to ``list[low:high]``. Indexing from the end of the list is not supported. |
There was a problem hiding this comment.
By itself, this is not obviously much of an improvement, but in the context of the earlier sentence for PyList_GetItem, "The position must be non-negative; indexing from the end of the list is not supported.", I think it is.
There was a problem hiding this comment.
Technically, negative indices are supported. But they do not count from the end.
|
Thanks @serhiy-storchaka for the PR 🌮🎉.. I'm working now to backport this PR to: 2.7, 3.7, 3.8. |
|
GH-16933 is a backport of this pull request to the 3.8 branch. |
|
GH-16934 is a backport of this pull request to the 3.7 branch. |
|
GH-16935 is a backport of this pull request to the 2.7 branch. |
copy-and-paste error from python#16925
https://bugs.python.org/issue38557