From: Trans Date: 2008-03-15T01:25:57+09:00 Subject: Re: next(n), succ(n) ? On Mar 4, 8:47 am, Trans wrote: > Can anyone see any reason against adding an optional parameter to > #succ/#next? Eg. > > def succ(n=1) > s = self > n.times { s = s.next } > s > end > > It might be useful in some cases as an optimization. For instance in > Integer: > > def succ(n=1) > self + n > end > > I ask not just a possible suggestion for Ruby itself, but mainly b/c > it's one of the few core overrides I provide in Facets, and I want to > make sure that there isn't some substantial issue with the idea that > should convince me to take it out. No one has any thoughts on this whatsoever? T.