From: Love U Ruby Date: 2013-03-18T14:43:41+09:00 Subject: Re: confusion with singleton method call D. Deryl Downey wrote in post #1102022: > > Dude, if you're going to try complex stuff like this, use your friggin > head. You keep attempting to do dumb ass stuff, but don't have a clue to > what you're doing. You're not thinking, nor even attempting to reason it > out. It didn't dawn on you that NUMBERS are different than their base > class? What good would defining a singleton on the number 11 do? > NOTHING! I don't know how much you understand my above question,which is so valid. From the doc: http://www.ruby-doc.org/core-2.0/Fixnum.html Clearly mentioned that - ***There is effectively only one Fixnum object instance for any given integer value, so, for example, you cannot add a singleton method to a Fixnum.** The same I agreed for Bignum,FLoat and Symbol. Now the `true`,`false` and `nil` also has fixed Object_id, But why they are allowed to have singleton class on them. -- This is my curiosity to know and I think which is to legitimate. Thanks. -- Posted via http://www.ruby-forum.com/.