From: Phrogz Date: 2007-01-18T06:45:07+09:00 Subject: Re: const initialization David Weldon wrote: > I think ruby does something strange when it decides if certain constants > have been initialized or not. [snip] It has nothing to do with constants in particular, but (as you were referring to at the end) whether or not Ruby thinks two required files are the same. See this: C:\>type tmp.rb p( require( 'const' ) ) p( require( 'const.rb' ) ) p( require( 'c:/const.rb' ) ) C:\>ruby tmp.rb true false c:/const.rb:1: warning: already initialized constant FOO true The 'false' means that Ruby could tell that it was the same file, and didn't re-include it. The last 'true' means that Ruby didn't realize that the two path specifications ended pointed to the same file, and re-included it. That's when the warning goes off.