[MacRuby-devel] require module

Alan Skipp al_skipp at fastmail.fm
Mon Nov 29 05:14:21 PST 2010


Hi everyone,
This is just a quick query about using 'include' in an xcode project.
When creating an instance of a class, a 'require' statement is not needed beforehand, but to include a module, you must first require it.

#no need to require 'Foo'
x = Foo.new 

# must require 'Bar' beforehand
require 'bar'
include Bar 

Should this behaviour be more consistent?


More information about the MacRuby-devel mailing list