From: Phillip Gawlowski Date: 2007-04-24T12:10:15+09:00 Subject: Re: exception and $! Paul Rogers wrote: > Thanks, I actually wanted to see what the last exception was out side > of a block, kind of like this > begin > raise "bad" > rescue => e > puts "#{e} was raised" > end > puts "Just to make sure, last exception was #{$!}" If you change the above into puts "Just to make sure, last exception was #{e}" you get what you want. -- Phillip "CynicalRyan" Gawlowski http://cynicalryan.110mb.com/ http://clothred.rubyforge.org Rules of Open-Source Programming: 22. Backward compatibility is your worst enemy. 23. Backward compatibility is your users' best friend.