[issue47178] Improve the implementations of Sequence.index and MutableSequence.extend in collections.abc

2022-03-31 Thread Raymond Hettinger
Raymond Hettinger added the comment: Marking as closed because the changes are incorrect. See the comments in the PR. -- assignee: -> rhettinger nosy: +rhettinger resolution: -> rejected stage: -> resolved status: open -> closed ___ Python

[issue47178] Improve the implementations of Sequence.index and MutableSequence.extend in collections.abc

2022-03-30 Thread Géry
New submission from Géry : This P.R. will make the following changes to the `collections.abc` module: - simplify the implementation with slicing in function `Sequence.index`. - remove an unnecessary copy of `self` when a sequence extends itself in function `MutableSequence.extend`. --