Skip to content

gh-125420: implement Sequence.index API on memoryview objects #125446

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged

Conversation

picnixz
Copy link
Member

@picnixz picnixz commented Oct 14, 2024

I went for the simplest implementation. I could unroll the memory_item call to save some operations but I felt that it would only add noise and make maintenance harder so I went for a cleaner but probably a bit slower option.


📚 Documentation preview 📚: https://cpython-previews--125446.org.readthedocs.build/

@picnixz
Copy link
Member Author

picnixz commented Nov 6, 2024

Since you've approved the .count() PR, I think you want to have a look at this one as well @JelleZijlstra.

@JelleZijlstra JelleZijlstra merged commit 58c7538 into python:main Dec 10, 2024
45 checks passed
@picnixz picnixz deleted the fix/memoryview-sequence-api-index-125420 branch December 10, 2024 08:25
srinivasreddy pushed a commit to srinivasreddy/cpython that referenced this pull request Jan 8, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants