From: dblack@... Date: 2003-04-25T19:31:43+09:00 Subject: Re: Hashes and Enumerable#each_with_index Hi -- On Fri, 25 Apr 2003, Ryan Pavlik wrote: > On Fri, 25 Apr 2003 15:25:14 +0900 > matz@ruby-lang.org (Yukihiro Matsumoto) wrote: > > > > I'm positive. But describe what you want more precisely. The > > following behavior OK for you? > > > > Suppose it is called "each_with_foo": > > > > * each_with_foo should be available for all built-in classes that > > have obj[x] access. > > > > * each_with_foo must give (x,y) that obj[y] == x be true always. > > > > Replace "foo" with the right word. I don't think it's "key", since > > Array index is not key after all. > > David Black (iirc) had a good suggestion on #ruby-lang, and that was > "each_pair". It was flgr -- not sure who that is though. David -- David Alan Black home: dblack@superlink.net work: blackdav@shu.edu Web: http://pirate.shu.edu/~blackdav