-
Notifications
You must be signed in to change notification settings - Fork 2.6k
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
[Feature Request] Support popitem()
for Dict
#2355
Labels
enhancement
New feature or request
good first issue
Good for newcomers
help wanted
Extra attention is needed
mojo-repo
Tag all issues with this label
Comments
jayzhan211
added
enhancement
New feature or request
mojo
Issues that are related to mojo
labels
Apr 20, 2024
JoeLoser
added
mojo-stdlib
Tag for issues related to standard library
good first issue
Good for newcomers
and removed
mojo-python-interop
labels
May 4, 2024
modularbot
pushed a commit
that referenced
this issue
Jun 1, 2024
Implement `Dict.popitem()` which removes and returns the last item in the `Dict`. Fixes #2355. Reapply after it got reverted now that the UB in `reversed()` for `Dict` has been fixed. MODULAR_ORIG_COMMIT_REV_ID: d8bf29ed0aeb6d59a9a0a3af650ce141993faa83
modularbot
pushed a commit
that referenced
this issue
Sep 13, 2024
Implement `Dict.popitem()` which removes and returns the last item in the `Dict`. Fixes #2355. Reapply after it got reverted now that the UB in `reversed()` for `Dict` has been fixed. MODULAR_ORIG_COMMIT_REV_ID: d8bf29ed0aeb6d59a9a0a3af650ce141993faa83
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
enhancement
New feature or request
good first issue
Good for newcomers
help wanted
Extra attention is needed
mojo-repo
Tag all issues with this label
Review Mojo's priorities
What is your request?
Python Dict has
popitem()
Remove and return a (key, value) pair from the dictionary. Pairs are returned in LIFO order
What is your motivation for this change?
I'm not sure if this is an important method (non syntactic sugar), if yes I can help to work on it, otherwise we hold it and work on others
Any other details?
No response
The text was updated successfully, but these errors were encountered: