On Oct 23, 1:06     

> Dude, instance variables are not inherited in this way. Every object
> gets its OWN instance variable table, including the Object class. There
> is no confusion and no mix up, behold:
>
> class X
> def self.to_a
> @a || = 10
> end
> end
>
> class Y
> def self.to_a
> @a ||= 20
> end
> end
>
> X #=> 10
> Y #=> 20
>
> class Object
> @a = 30
> end
>
> X #=> 10
> Y #=> 20
>
> @a #=> 30
>
> Having the instance variables on the Object class would NOT cause any of
> the conflicts you guys are talking about :)

You're right. I extrapolated from the instance case and made a
mistake.

It's still a bad idea to have main and Object intertwined for the
other reasons I have mentioned, so if anything changes I'd rather see
it change in that regard. But with regards to the current
functionality of Ruby, other than toplevel methods being made private,
I do not see any  significant difference. As your correction to my
error points out, the toplevel instance variables are not currently
the same as Object class' instance variables. But I don't think it
would be a problem if they were. So you may well be right --main could
just as well be the Object class itself and everything would work as
before.

(Interestingly I played around with class variables (@@a) and they in
fact can be changed from the toplevel, effecting any class already.)