From: Ross Bamford Date: 2006-05-11T16:17:24+09:00 Subject: Re: Module#add_tracer On Thu, 2006-05-11 at 08:44 +0900, Logan Capaldo wrote: > On May 10, 2006, at 7:34 PM, Victor Shepelev wrote: > > Of cause I know about this. My solution is much more lightweight > > (because > > only one function of one class would be slow down). > > > > Yours also breaks when someone else overrides the same method and > aliases it to old_#{meth} (Which, unfortunately is pretty common.) I've started aliasing like this: __filename__methodname__ e.g, in foo.rb, it'd be __foo__somemethod__. Not sure if it's really much help when it comes to these problems, but it seems like a good idea at the time :) -- Ross Bamford - rosco@roscopeco.REMOVE.co.uk