From: dblack@... Date: 2003-08-13T04:07:21+09:00 Subject: Re: Nested class/module namespace Hi -- On Wed, 13 Aug 2003, Yukihiro Matsumoto wrote: > Hi, > > In message "Nested class/module namespace" > on 03/08/12, "Nathaniel Talbott" writes: > > |Why does the second case fail? It makes me not want to use the second > |version, since it means I have to fully-qualify all constants in the > |enclosing namespace, instead of just using them as I usually do. I hope it's > |just a bug :-/. > > Unfortunately, it's not. "class M::C" notation is not a syntax sugar > for 'module M; class C". It is something like "M::C = Class.new", so > that the body of C definition is not nested in the M body. At first glance this seems like a loss. Are there times when there's an advantage to having it work that way? David -- David Alan Black home: dblack@superlink.net work: blackdav@shu.edu Web: http://pirate.shu.edu/~blackdav