Issue #5185 has been updated by knu (Akinori MUSHA).


I feel it's hard to change this by now since #merge is a library method (for subclasses) rather than just a user method, but I could add #update as an alias for #merge and then obsolete #merge which would eventually be end-of-life'd.

----------------------------------------
Feature #5185: Set#merge acts in place but Hash#merge does not
https://bugs.ruby-lang.org/issues/5185#change-26678

Author: trans (Thomas Sawyer)
Status: Assigned
Priority: Normal
Assignee: knu (Akinori MUSHA)
Category: lib
Target version: 2.0.0


Waste of brain cells to have to learn and recall they are different. The expected method would be Set#merge!, Set#merge would return a new Set instance.

OTOH, why not Set#concat ? Or conversely, Array#merge ?




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