Issue #12512 has been updated by Jan Friedrich.


Yukihiro Matsumoto wrote:
> `#map_v` accepted.

At first I thought it was an "adapted form" of Hash#map like Enumerable#grep_v is an "inverted" Enumerable#grep. Maybe the "_v" could be confusing for other people?

Why not Hash#map_values - we have Enumerable#each_with_object, Enumerable#each_with_index and others, Hash#keys, Hash#values, Hash#values_at and other "full forms" of methods?

----------------------------------------
Feature #12512: Import Hash#transform_values and its destructive version from ActiveSupport
https://bugs.ruby-lang.org/issues/12512#change-60023

* Author: Kenta Murata
* Status: Closed
* Priority: Normal
* Assignee: Kenta Murata
----------------------------------------
I think value transformation is a fundamental feature of Hash.



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

Unsubscribe: <mailto:ruby-core-request / ruby-lang.org?subject=unsubscribe>
<http://lists.ruby-lang.org/cgi-bin/mailman/options/ruby-core>