Issue #6225 has been updated by alexeymuranov (Alexey Muranov).


Just a thought about Hash#+: maybe it can be used for merging only hashes with disjoint sets of keys, and return nil otherwise?
----------------------------------------
Feature #6225: Hash#+
https://bugs.ruby-lang.org/issues/6225#change-41128

Author: trans (Thomas Sawyer)
Status: Rejected
Priority: Normal
Assignee: matz (Yukihiro Matsumoto)
Category: core
Target version: next minor


Strings and Arrays can be combined with #+. I don't see any reason not to allow Hashes to do so as well.

  class Hash
    alias :+ :merge
  end



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