Hello, I have two ruby files. The first is
require 'www/poster'
poster = Poster.new()
The second ('www/poster.rb') is
require ...
class Poster ... end
The problem is, when I run the first file, I get an error: in `': uninitialized constant Poster (NameError) But if I replace the original code with just
require ...
class Poster
end
__END__
class Poster #original class here
it's ok. The code worked fine in Ruby 1.8.6, problems started after upgrading to 1.9.1p129 (2009-05-12 revision 23412) [i386-mswin32]. Is there any workaround? TIA