I think this used to produce sorted output in 1.8.2:
irb(main):002:0> h = {}
=> {}
irb(main):003:0> 10.times {|i| h[i] = i}
=> 10
irb(main):004:0> puts h.to_yaml(:SortKeys => true)
5: 5
0: 0
6: 6
1: 1
7: 7
2: 2
8: 8
3: 3
9: 9
4: 4
=> nil
Is there still a way to do this?