From: why the lucky stiff Date: 2005-02-22T03:26:07+09:00 Subject: Re: YAML and hash Artur Merke wrote: >Hi, > >is there a possibility to recognize multiple keys while >reading a hash using YAML? > >example: > >arr= YAML::load("aaa: 1\nbbb: 2\naaa: 3" ) >=> {"aaa"=>3, "bbb"=>2} > >but I would like to get a warning or an exception when >encountering the key 'aaa' for the second time, and not just >get the first entry overwritten. > You're right. This should throw an error or a warning (according the YAML specification). This a simple fix, but cannot be done in Ruby. I've added this to the bug tracker on RubyForge. Thankyou! _why