From: Ryan Pavlik Date: 2003-04-25T15:00:24+09:00 Subject: Re: Hashes and Enumerable#each_with_index On Fri, 25 Apr 2003 07:40:47 +0900 dblack@superlink.net wrote: > Hi -- > > On Fri, 25 Apr 2003, Ryan Pavlik wrote: > > > Would it not be more useful to adopt the definiton of > > Enumerable#each_with_index where the index given is such that e[i] == o > > for any given Enumerable? > > One problem I see is: how could you implement this, in Enumerable, in > terms of #each? > I don't see why there must exist a default implementation in Enumerable... this is a good example of why. I personally have no preference as to whether it has a new name or not, but I'm guessing there's little choice since likely a good deal of code already exists that relies on the current behavior. -- Ryan Pavlik "Now is not the time for sarcasm! Now is the time for nefarious action." - 8BT