- or download this
/tmp>cat error.c
#include <stdio.h>
...
failed to open foo: No such file or directory
/tmp>
- or download this
try {
line = console.readLine();
...
finally {
console.printLine("The program is now terminating.");
}
- or download this
use Try::Tiny;
$dbh->{AutoCommit} = 0; # enable transactions, if possible
...
eval { $dbh->rollback };
# add other application on-error-clean-up code here
};
- or download this
$h->method(@args) or die $h->errstr;