code: def _update_with_replace(self, other, key, val=None, **options):
      
      self[key] = other[key] if val is None else val
docs: Replace value of a mapping object 'self' with 'other' has if both have same
      keys on update. Otherwise, just keep the value of 'self'.
  
      :param self: mapping object to update with 'other'
      :param other: mapping object to update 'self'
      :param key: key of mapping object to update
      :param val: value to update self alternatively
  
      :return: None but 'self' will be updated