From: Robert Klemme Date: 2004-05-24T17:48:45+09:00 Subject: Re: Overriding "", [], and {} "Hal Fulton" schrieb im Newsbeitrag news:40AD305C.6030408@hypermetrics.com... > Robert Klemme wrote: > > "why the lucky stiff" schrieb im > > Newsbeitrag news:40AD161F.6070107@whytheluckystiff.net... > > >> >> o = YAML::Omap['c', 'coats', 'g', 'goats'] > >> => [["c", "coats"], ["g", "goats"]] > >> >> o.class > >> => YAML::Omap > >> > >>_why > > > > > > or how about > > > > oh = OrderedHash.new.update( { > > "foo" => "bar", > > "bar2 => "foo", > > } ) > > But then the order in the "ordered hash" is not necessarily the same > as that specified in the single hash passed in as a parameter. My fault, I forgot that OrderedHash maintains insertion order and not some other order. Sorry, just forget my proposal. robert