Usage:
Where EXPR is, of course, an expression. For example:use Silly::Die; EXPR or die trying;
open FILE, "foo" or die trying;
package Silly::Die; sub import { my $class = shift; my $caller = caller; no strict 'refs'; *{"${caller}::trying"} = \&{"${class}::trying"}; } sub trying { $! } 1;
In reply to Completely Useless by btrott
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |