From: Dave Thomas Date: 2000-07-03T20:07:26-05:00 Subject: [ruby-talk:03780] Re: modulo and remainder Tadayoshi Funaba writes: > hello, > > At 2000-07-04T02:33:08+0900 (2451729.23134JD), > matz@netlab.co.jp (Yukihiro Matsumoto) wrote: > > matz> |However, in the old scheme of things, these were different operators. > matz> | > matz> |Has the decision now been made to unify them? > > matz> In short, yes. > > I hope not. > > I wrote a method jd_to_wday in date2.rb like this: > > def jd_to_wday(jd) (jd + 1) % 7 end So is date2 now broken with 1.5.4? Perhaps we need a method .modulo. The problem then is with .divmod. If that returns a modulo, rather than a remainder, then the q*y+r = x relation is broken. So then maybe we'd need to add .divrem too... And so it goes. All this a day before the 16 freeze too. If this change has broken existing libraries, my vote would be to revert to the old behavior and let's dicuss this some more for 1.8. Regards Dave