From: Gregor Kopp Date: 2006-12-22T19:35:05+09:00 Subject: Re: class method Gregor Kopp schrieb: > Spitfire schrieb: > >> One thing that I don't understand is the following code. >> >> sample = [1,2,3] >> p sample.class #=> Array >> p sample.class.is_a?(Array) #=> false >> p sample.class.is_a?(Array.class) #=> true (why???) >> > > sample = [1,2,3] > p sample.class #=> Array > p sample.is_a?(Array) #=> true isa? makes checks with .class in the Background automagically.