Trans
7/2/2007 10:32:00 AM
On Jul 2, 5:34 am, "Ronald Fischer" <ronald.fisc...@venyon.com> wrote:
> > # Defining a module in one file
> > module M
> > module_function # <<<<<<<<< HERE
> > def f(x)
> > ....
> > end
> > end
>
> Thank you, this is indeed one solution to my problem (though in the
> end, I'm going to stick with Michael Hollins' proposal).
Don't mention it :) BTW, Just to make sure you know, you can't use
Micheal's solution if you still want the option of including the
Module elsewhere. In effect using module_function is the same as:
module M
def self.f(x)
....
end
def f(x)
....
end
private :f
end
Probably you've already figured that out, but just in case...
T.