From: jmichel@... (Jean Michel) Date: 2001-02-20T00:40:02+09:00 Subject: [ruby-talk:11107] Re: Summary: RCR #U002 - proper new name for indexes James T. Vradelis wrote: > >I'd like to see: > > (k) Hash#[], Array#[] > >as in: > > myHash = {'one' => 1, 'two' => 2, 'three' => 3} > > myHash['one','two','three'] -> [1,2,3] > >and > > myArray = [1,2,3,4,5] > myArray[4,2,3] -> [5,3,4] > >I realize that this latter conflicts with: > > Array#[, ] > >but that functionality is duplicated by: > > Array#[..] I must say that despite the fact that this would change incompatibly the language in a big way, I like very much this proposal. Much cleaner than current ruby semantics, in my opinion. But probably not feasible :( Best regards, Jean MICHEL