From: ara.t.howard@... Date: 2006-12-12T02:53:11+09:00 Subject: Re: bending ruby space On Tue, 12 Dec 2006, Trans wrote: > > ara.t.howard@noaa.gov wrote: >> harp:~ > cat a.rb >> module X >> module_function # side effect -> instance 'f' made private >> def f; "f"; end >> public :f >> # ^^^^^^ ^^ >> # ^^^^^^ ^^ >> # ^^^^^^ ^^ >> end > > but that undoes the module_function-ality of X. ?? harp:~ > cat a.rb module X module_function # side effect -> instance 'f' made private def f; "f"; end public :f end p X.f include X p self.f harp:~ > ruby a.rb "f" "f" -a -- if you want others to be happy, practice compassion. if you want to be happy, practice compassion. -- the dalai lama