From: Clifford Heath Date: 2011-05-27T09:16:30+09:00 Subject: [ruby-core:36500] Re: Error reporting, backtraces and the debugger On 26/05/2011, at 10:34 AM, Asher wrote: > I've implemented an objective backtrace and some other tools in > Sender: https://rubygems.org/gems/sender The textual backtrace already had the method and object name. Sender adds the object in each frame (nice!), but seems to add little else, other than the convenience methods...? Have I misunderstood? Also, when I talk about the frame, I want the binding context for parameters and local variables, so you can explore and enumerate those. You might be curious to read some interesting stuff I explored in this gist: . It enables interesting "foreign" DSLs to be integrated into Ruby in a way that allows interaction with the local variables of the *caller*, so for example you can do stuff like: def test param = "foo" result = nil foreign_language{%q{ -- Some text in a foreign DSL which can read and modify caller's vars result = param+"bar" }} p result end test => "foobar" Yes, really. Read that again! Interesting stuff. It uses the binding of the passed-in block as an access point to seeing the variables. So that's what got be thinking that the debugger should be able to use the binding in a backtrace to see and modify local variables and parameters in the call stack. Clifford Heath.