From: Reginald Tan Date: 2012-07-04T07:21:07+09:00 Subject: Re: Using binding + set trace func to capture execution state > Why would the debugger not work for you? If you know the line (as you > said earlier) you can use that information to set a breakpoint and > inspect data when you've hit the breakpoint. > > Can you explain what goal you are trying to achieve? > Sure. I want to create a tool that allows me to quickly be familiar with 3rd party libraries or any existing legacy code base that I'll be maintaining. ctags is pretty helpful in terms looking at the complete method call chain being executed but is not helpful in getting a big picture of what's going on with how my data is being transformed from one line to another. Debuggers on the other hand, would give me that flexibility of inspecting variables, but I've experienced too much repetitive typing of 's' for "step" and 'n' for "next" and I find that experience really frustrating. Moreover, since the ruby debugger only allows you to move forward, i would have to restart the debugging session again if i want trace things backwards. So I guess what I want is the combine the power of 'ctags' and 'ruby-debug', and create a tool that will output the callgraph of ruby program or method, wherein not only would I be able to see the source code of each method call, i would also be able to inspect the variables backward or forwards and at any line of the execution. I believe this will give me a big picture of a codebase and see how one section of the code relates to another :) -- Posted via http://www.ruby-forum.com/.