From: Matthew Kerwin Date: 2013-02-07T17:55:01+09:00 Subject: [ruby-core:51971] Re: [ruby-trunk - Feature #7796][Open] Hash#keys should return a set --f46d042f9f9a15e7fd04d51e8f28 Content-Type: text/plain; charset=ISO-8859-1 On 7 February 2013 17:52, alexeymuranov (Alexey Muranov) < redmine@ruby-lang.org> wrote: > > =begin > In my opinion, (({Hash#keys})) should return an instance of (({Set})). > =end > > Is this related to an earlier request to create OrderedHash as an alias of Hash? If that were to happen, I'd be happy if OrderedHash#keys returned an Array, and Hash#keys returned a Set. However if Hash remains explicitly ordered, Hash#keys should be likewise explicitly ordered (i.e. an Array). Unless we're also adding to spec that Set is insertion-ordered. -- Matthew Kerwin, B.Sc (CompSci) (Hons) --f46d042f9f9a15e7fd04d51e8f28 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable
On 7= February 2013 17:52, alexeymuranov (Alexey Muranov) <= redmine@ruby-lan= g.org> wrote:

=3Dbegin
In my opinion, (({Hash#keys})) should return an instance of (({Set})).
=3Dend


Is this related to an earlier= request to create OrderedHash as an alias of Hash?=A0 If that were to happ= en, I'd be happy if OrderedHash#keys returned an Array, and Hash#keys r= eturned a Set.=A0 However if Hash remains explicitly ordered, Hash#keys sho= uld be likewise explicitly ordered (i.e. an Array).=A0 Unless we're als= o adding to spec that Set is insertion-ordered.

--
=A0 Matthew Kerwin, B.Sc (CompS= ci) (Hons)
--f46d042f9f9a15e7fd04d51e8f28--