From: "ara.t.howard" Date: 2010-10-13T11:17:53+09:00 Subject: Re: map-1.3.0 1) symbols are not GC'd 2) all external input is string (eg. yaml) symbols as keys are a feature that saves on char and costs many hours. On Oct 12, 12:30 pm, unbewusst.s...@fai.invalid (Une Bévue) wrote: > ara.t.howard wrote: > > map does use strings: > >http://github.com/ahoward/map/blob/master/lib/map.rb#L123 > > why did u choose this feature, i was surprised of that : > require 'rubygems' > require 'map' > > m=Map[{:un => 1, :deux => 2, :trois => 3, :quatre => 4}] > puts "# => m.keys.first.class = #{m.keys.first.class}" > # => m.keys.first.class = String > --------------------------^^^^^^^ > i expected Symbol... > (clearly that's your line 123 : > key.kind_of?(Symbol) ? key.to_s : key) > > because of ordering ? > > -- >   N'essayez pas de noyer vos chagrins : ils savent nager. >     (Albert Willemetz)