Hi,

In message "Thought question: Where does "new" come from?"
    on 02/08/15, "Hal E. Fulton" <hal9000 / hypermetrics.com> writes:

|How would you explain where "new" comes from
|in a class?

From the Class class.

|This arose because I was trying to draw a picture
|of Ruby's entire object model.

Did you check the chart in object.c?

    /*
     * Ruby's Class Hierarchy Chart
     *
     *                           +------------------+
     *                           |                  |
     *             Object---->(Object)              |
     *              ^  ^        ^  ^                |
     *              |  |        |  |                |
     *              |  |  +-----+  +---------+      |
     *              |  |  |                  |      |
     *              |  +-----------+         |      |
     *              |     |        |         |      |
     *       +------+     |     Module--->(Module)  |
     *       |            |        ^         ^      |
     *  OtherClass-->(OtherClass)  |         |      |
     *                             |         |      |
     *                           Class---->(Class)  |
     *                             ^                |
     *                             |                |
     *                             +----------------+
     *
     *   + All metaclasses are instances of the class `Class'.
     */

And of course, all classes are instances of the Class too.

							matz.