#792: Hash#delete is broken. ----------------------------------+----------------------------------------- Reporter: watson1...@… | Owner: lsansone...@… Type: defect | Status: new Priority: blocker | Milestone: Component: MacRuby | Keywords: ----------------------------------+----------------------------------------- Test Script: {{{ $ cat test_hash.rb h = { 1 => 'one', 2 => 'two', 3 => 'three', self => 'self', true => 'true', nil => 'nil', 'nil' => nil }
h.each do |k, v| p "#{k} : #{v}" p h.delete(k) end p "Result: #{h}" }}} Result of Ruby 1.9.1: {{{ $ ruby test_hash.rb "1 : one" "one" "2 : two" "two" "3 : three" "three" "main : self" "self" "true : true" "true" " : nil" "nil" "nil : " nil "Result: {}" }}} Result of MacRuby Trunk: {{{ $ macruby test_hash.rb "1 : one" "one" "false : false" nil "Result: {2=>\"two\", 3=>\"three\", main=>\"self\", true=>\"true\", nil=>\"nil\", \"nil\"=>nil}" }}} -- Ticket URL: <http://www.macruby.org/trac/ticket/792> MacRuby <http://macruby.org/> _______________________________________________ MacRuby-devel mailing list MacRuby-devel@lists.macosforge.org http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel