From: Andrew Hunt Date: 2000-03-31T11:33:49-05:00 Subject: [ruby-talk:02301] Re: DBC >> My Rube-Goldberg attempt used tracefunc to hook into the dispatcher, >> so that I could check every method call and see if a pre/post condition >> existed and then call it. This also gave me the opportunity to call >> invariant on exit from every method call. >> >> /\ndy >> > >I was LOOKING for a mechanism like that! > >How did you know it existed? From digging in the code >or what? As with most things, we found it from digging :-) Have a look at tracer.rb and debug.rb as well as set_trace_func in eval.c I had to modify the Binding object to throw in some extra state; but I'm not convinced that was necessary. /\ndy