From: patrick-may@... (Patrick May) Date: 2002-09-14T15:45:10+09:00 Subject: Re: not grasping the method overloading/multi-dispatch thing I just got a better idea for RHDL: class Signal def call proc{self.to_s}.call end #.... def assign_at (relTime=0,nextValue=Proc.new) nextValue = nextValue.call if nextValue.respond_to? :call @eventQueue[relTime] = nextValue nextValInQueue = @eventQueue.shift @next_value = nextValInQueue if nextValInQueue end def assign(nextValue=Proc.new) assign_at(0,nextValue) end #.... end 2 changes: * made the common function call, so you don't have to change Proc * made function.call a guard, so that you don't have to change Object This is kind of cheating, since I'm checking some type. But this is why I like Ruby giving a way to do so, even if I don't prefer it :-) ~ Patrick