Ruby on Rails
Wednesday, September 26, 2012
inheritance chain:
Class -> Module -> Object
Kernel.is_a?(Module) # => true
Kernel is an instance of Module, which in turn inherits from Object.
So how is Kernel an ancestor of Object?
I found it on line 262 of "The Ruby Programming Language":
"The Kernel module is an ancestor of Object."
--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment