How to "go to" in a RUBY script . .

<snip>

catch(:block) do ... end

Between that and redo you should be good to go. Prolly slower, though.

Regards,

Dan

This communication is the property of Qwest and may contain confidential or
privileged information. Unauthorized use of this communication is strictly
prohibited and may be unlawful. If you have received this communication
in error, please immediately notify the sender by reply e-mail and destroy
all copies of the communication and any attachments.

···

-----Original Message-----
From: Leslie Viljoen [mailto:leslieviljoen@gmail.com]
Sent: Thursday, May 18, 2006 2:49 PM
To: ruby-talk ML
Subject: Re: How to "go to" in a RUBY script . . .

On 5/18/06, DEBAUN, STEVE [AG-Contractor/2400] > <steve.debaun@seminis.com> wrote:
> To everyone else:
> I'll distract him, while y'all get a rope.

hehe. I recently noticed that C# still has a goto, although
it seems that you can't have a label right at the end of a
function since the label must precede an actual statement. I
found it to be useful in a case where I was deep in nested
loops, searching for a string and had just found it, so I
needed to jump out. It seemed so much clearer and simpler to
use the goto rather than have

if (... & flag_variable)

in every loop condition., even though I had to put silly nop
statements at the end of the functions.