Well I''ve figured that out
M::C1.new() will not find method1
while
include M
C1.new() will
On 9/4/05, Bogdan Ionescu
<bogdan.ionescu-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
wrote:>
> I have:
>
> Module M
> def method1
> ...stuff
> end
> class C1
> def initialize
> call_method1
> end
> end
> end
>
> How can i call method1 from inside C1?
> The only way I found was to do an "include M" in C1, but that
seems like a
> hack to me.
>
> thanks,
> bogdan
>
>
_______________________________________________
Rails mailing list
Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org
http://lists.rubyonrails.org/mailman/listinfo/rails