Beefy Boxes and Bandwidth Generously Provided by pair Networks
Keep It Simple, Stupid
 
PerlMonks  

Re: Re: Style Point: Catching eval { } errors

by dref (Novice)
on Nov 28, 2003 at 12:29 UTC ( [id://310710]=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    sub try (&@) {
      my($code, $error_handler) = @_;
    ...
    sub catch (&) {
      return @_;
    }
    
  2. or download this
    my $msg;
    try {
    ...
      print "File could not be opened because of: $@\n";
      $msg = "BAAAAH";
    }
    

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://310710]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others taking refuge in the Monastery: (3)
As of 2024-04-26 01:11 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found