From: Oscar Del Ben Date: 2008-06-14T19:57:05+09:00 Subject: Re: Modules, Overloading, and some Confusion ------=_Part_5548_7003119.1213441066541 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline Use namespace.Honda::start 2008/6/14, Old Echo : > > Hello Rubyists, > Here's something I've been pondering lately and was hoping to get a good > response from someone out in the community. It's about having two > modules which both implement a method with the same name, and then > including both modules into a class. > > Example: > > module Honda > def start > puts "Wroom" > end > end > > > module Ford > def start > puts "Rrrooom" > end > end > > class Car > include Honda > include Ford > end > > car = Car.new > car.start > => Rrrroooom > > > Okay, so that's a pretty contrived example, but here's my question: how > can I can call the start method defined in Honda rather than the start > method defined in Ford? I feel like there's something I'm missing here, > but I'm not sure what it is. > > Thanks all, > kodama > > -- > Posted via http://www.ruby-forum.com/. > > ------=_Part_5548_7003119.1213441066541--