>>>>> "Chris" == Chris Devers <[EMAIL PROTECTED]> writes:

Chris> On Thu, 31 Mar 2005, Ankur Gupta wrote:
>> No I do not [want to] die so fast.. I want to do some processing based 
>> on the died message.

Chris> Fine then.

Chris>     eval {
Chris>         risky_action();
Chris>     }

You forgot a semicolon here, which will make Perl start to think
you mean this to be an "if" modifier instead of a separate if statement.
Wheeee!

Chris>     if $@ {
Chris>         my $status = $@;
Chris>         my $result = do_some_processing();
Chris>         die "Got $status, did some processing: $result\n";
Chris>     }

Chris> This should work. 

Yes, it *should*, and doesn't. :)

-- 
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
<merlyn@stonehenge.com> <URL:http://www.stonehenge.com/merlyn/>
Perl/Unix/security consulting, Technical writing, Comedy, etc. etc.
See PerlTraining.Stonehenge.com for onsite and open-enrollment Perl training!

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>


Reply via email to