From: Zev Blut Date: 2004-08-30T12:52:55+09:00 Subject: Re: Typos (Was: performance comparison) Hello, On Sun, 29 Aug 2004 23:12:22 +0900, Alexey Verkhovsky wrote: > > Try "irb --noprompt". > > To me, the biggest problem with using irb in this mode is the "set up > some context" part. > > Believe it or not, but it is quite easy to do with Eclipse/Java: one can > set a breakpoint, execute some test, wait till debugger stops on the > breakpoint, and then use Eclipse "Display" view to evaluate arbitrary > Java expressions in the current scope. > > So far, I don't know any easy way to do the same with Ruby, so I end up > inserting things like "puts .inspect" and rerunning the > test. Which is not as nice as an interactive shell. Does anyone have a > better way? In addition, to Florian Gross' nice technique, you could also use the Ruby Debugger instead of IRB. Just run your program with "ruby -r debug yourprog.rb". Even better, if you use Emacs, is the ruby debugger mode for it "M-x rubydb". Of course, this is not as transparent as Eclipse... Cheers, Zev