Hi,

I have a class inheriting from Hash which has some specific methods
operating on the hash elements:

Class MyHash < Hash

  def foo
  ...
  end

End

 ....

Now, with Hash class, its really easy to create a new hash, eg

h = {:key1 => "val1", :key2 => "val2"}

What I would like to do is create a new instance of the class with the
same simplicity, but I'd like to avoid creating a redundant Hash and
tranferring the contents one by one to MyHash which happens if I code:

h = MyHash.new(:key1 => "val1", :key2 => "val2")

and then define initialize(h={})

Whats the "ruby way" tm for something like this?

Thanks

Nev