Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl Monk, Perl Meditation
 
PerlMonks  

Re: "Obviously, You Will Need a Java Course..."

by darobin (Monk)
on Apr 04, 2001 at 15:27 UTC ( [id://69620]=note: print w/replies, xml ) Need Help??


in reply to "Obviously, You Will Need a Java Course..."

Actually, open(FH,"myFile.txt") or die "Nope : $!\n"; isn't really equivalent to the try-catch part above. A closer moral equivalent would be:

eval { open FH, '<my_file' or die $!; }; print $@ if $@;

...or of course a number of other possible Perl constructs around the same idea.

-- darobin

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others romping around the Monastery: (3)
As of 2024-04-25 23:50 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found