Pat Maddox
10/23/2007 10:04:00 PM
On 10/23/07, Thufir <hawat.thufir@gmail.com> wrote:
> On Oct 23, 2:45 pm, "Rick DeNatale" <rick.denat...@gmail.com> wrote:
> [...]
> > print is an instance method of the Kernel module.
> >
> > The Object class includes Kernel, so the instance methods of Kernel
> > are effectively instance methods of every object, at least in Ruby
> > 1.8.
> [...]
>
> Kernel is a class, sub-class, of Object?
>
>
>
> -Thufir
>
>
>
No, it's a module, and it's included into Object.
baggio:~ pergesu$ irb
irb(main):001:0> Kernel.class
=> Module
irb(main):002:0> Object.included_modules
=> [Kernel]
Pat