Perl functions as it does to be a good fit to intuition and natural language.</p?
A shell process's return value is the only way (aside from whatever it may have written to stderr) that status can be checked. Since there are many interesting ways for a process to fail, the ability to return different error codes is useful. Hence 0 == success, 0 != error_code.
It takes some getting used to.
After Compline,
Zaxo
In reply to Re: Re: Handling weird return values with or die
by Zaxo
in thread Handling weird return values with or die
by mvaline
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |