Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix Map#each and #each_pair not returning enumerator outside of MRI
When no block was passed to Map#each_pair or its alias Map#each, the NonConcurrentMapBackend would return an enumerator, which would allow enumerable methods to be used on a Map. But the alternate Map backends, JRubyMapBackend and AtomicReferenceMapBackend did not implement the same logic. As a fix, let's move the logic down to the shared Map class, so all implementations can use it. Fixes #643
- Loading branch information
Showing
3 changed files
with
21 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters