Beefy Boxes and Bandwidth Generously Provided by pair Networks
Your skill will accomplish
what the force of many cannot
 
PerlMonks  

perlfunc:exit

by gods
on Aug 24, 1999 at 22:43 UTC ( #314=perlfunc: print w/replies, xml ) Need Help??

exit

See the current Perl documentation for exit.

Here is our local, out-dated (pre-5.6) version:


exit - terminate this program



exit EXPR



Evaluates EXPR and exits immediately with that value. (Actually, it calls any defined END routines first, but the END routines may not abort the exit. Likewise any object destructors that need to be called are called before exit.) Example:

    $ans = <STDIN>;
    exit 0 if $ans =~ /^[Xx]/;

See also die(). If EXPR is omitted, exits with 0 status. The only universally portable values for EXPR are 0 for success and 1 for error; all other values are subject to unpredictable interpretation depending on the environment in which the Perl program is running.

You shouldn't use exit() to abort a subroutine if there's any chance that someone might want to trap whatever error happened. Use die() instead, which can be trapped by an eval().

All END{} blocks are run at exit time. See the perlsub manpage for details.


Log In?
Username:
Password:

What's my password?
Create A New User
Chatterbox?
[Corion]: Meh... Github (understandably) doesn't allow files larger than 100MB, but my rebase of an older repo (from Github) includes such a file and now I can't push my changes there
[Corion]: Maybe that is the push I need to finally try out Gitprep ;)
[Corion]: On the upside, I should finally improve Image::CCV to also do ImageNet classification using their pretrained parameters
[Lady_Aleena]: Hello Corion.

How do I use this? | Other CB clients
Other Users?
Others lurking in the Monastery: (4)
As of 2017-09-24 18:05 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    During the recent solar eclipse, I:









    Results (274 votes). Check out past polls.

    Notices?