From: gga Date: 2007-02-05T11:15:08+09:00 Subject: Re: Inheriting from Fixnum On 4 feb, 22:22, "gga" wrote: > Another thing probably worth looking is in how Python handles this > with their new classes in their C code, as it is definitively more > elegant than what Ruby does here (usually, it is the other way around, > but not for this). Well, I looked at how it is being done in Python2.5. Somewhat disappointed. There's nothing special about them, unlike ruby's handling of them. They are treated just like normal objects. The only smart thing about them in python is that the memory allocation for numbers is done from a memory pool, so they avoid calling malloc/free most of the time.