On 31 Aug 2001 12:01:15 +0900, Dave Vandervort wrote:
> > class OrderedHash < Hash

There's a bug in this as it stands...

> >         def []=(key, val)
> >                 @keys << key
> >                 super
> >         end

It's not checking to see if the key already exists. The Hash will
replace the old entry but the Array will append a new entry.

> >         def delete(key)
> >                 @keys.delete(key)
> >                 super
> >         end

Same problem.

Try probing for the key in the Hash (quick) to see what to do with the
Array.

Nice wrapper though.