From: Dave Thomas Date: 2002-10-17T04:53:40+09:00 Subject: Re: Psyco Paul Brannan writes: > On Thu, Oct 17, 2002 at 03:10:38AM +0900, Dave Thomas wrote: > > Now admittedly, the runtime could do some work to handle this, but it > > could be hard, particularly in the face of 'eval' and friends. You > > might have to keep the old bytecodes lying around, and reactivate them > > if you ever determine any operators such as '+' had been changed. > > Why allow the user to change the definition of Fixnum#+ to begin with? I don't know about '+', but I quite often change definitions of built-in operations. One of my current favorites is class NilClass def empty? true end end p nil.empty? Very useful for Web systems. If I can productively change operations in NilClass, then it would seem consistent to give me equivalent access to Fixnum. Or, or course, we could implement C# or Java where ints are native and have to be boxed before use. I wouldn't like to see this. Cheers Dave