lib/hashie/mash.rb
# Recursively merges this mash with the passed
# in hash, merging each hash in the hierarchy.
Recursively merges this mash with the passed
in hash, merging each hash in the hierarchy.
Recursively merges this mash with the passed in hash merging each hash in the hierarchy .
def deep_update(other_hash, &blk)
      other_hash.each_pair do |k, v|
        if regular_reader(k).is_a?(Mash) && v.is_a?(::Hash)
          custom_reader(k).deep_update(v, &blk)
        else
          value = convert_value(v, true)
          value = convert_value(blk.call(k, self[k], value), true) if blk
          custom_writer(k, value, false)
        end
      end
      self
    end
def deep_update ( other_hash , & blk ) other_hash . each_pair do | k , v | if regular_reader ( k ) . is_a? ( Mash ) && v . is_a? ( :: Hash ) custom_reader ( k ) . deep_update ( v , & blk ) else value = convert_value ( v , true ) value = convert_value ( blk . call ( k , self [ k ] , value ) , true ) if blk custom_writer ( k , value , false ) end end self end
Recursively merges this mash with the passed
in hash, merging each hash in the hierarchy.
Recursively merges this mash with the passed in hash merging each hash in the hierarchy .
other_hash
<not_specific>
blk
<not_specific>