Skip to content
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

Some Hash destructive methods ensure the receiver modifiable [Bug #17736] #4297

Merged
merged 1 commit into from
Mar 20, 2021

Conversation

kachick
Copy link
Member

@kachick kachick commented Mar 20, 2021

Do we need these change as #4296? 🤔

https://bugs.ruby-lang.org/issues/17736

This commit aims to cover following methods

  • Hash#select!
  • Hash#filter!
  • Hash#keep_if
  • Hash#reject!
  • Hash#delete_if

I think these are not all.

@nobu 🙏

…736]

refs:

* https://bugs.ruby-lang.org/issues/17736
* ruby#4296

This commit aims to cover following methods

* Hash#select!
* Hash#filter!
* Hash#keep_if
* Hash#reject!
* Hash#delete_if

I think these are not all.

---

* Ensure the receiver is modifiable or not
* Assert the receiver is not modified
@nobu nobu merged commit 7954bb0 into ruby:master Mar 20, 2021
@kachick
Copy link
Member Author

kachick commented Mar 20, 2021

Thank you!

@kachick kachick deleted the bug/17736-hash-some-destructive-methods branch March 20, 2021 11:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants