On Tuesday 18 October 2005 4:07 pm, Warren Seltzer wrote:
> There appear to be 2 separate exception mechanisms in Ruby, catch/throw and
> rescue/raise/retry.  Is this right?

Not really.  A throw just lets one unwind from some deep nesting without 
generating a back trace, passing some value along to the catch.

It is much faster and lighter weight than the exception mechanism, and should 
be used for cases where a fast, lightweight escape from some deep place is 
wanted, perhaps with some passing of data from the deep place to the shallow 
place, but where an actual exception isn't needed.


Kirk Haines