in reply to Re^2: What operator should perl5porters use for safe dereferencing?
in thread What operator should perl5porters use for safe dereferencing?
eval{} surely works. But it works too well. Far too well! It'll happily eat any exception whatsoever. Sure you will be able to tell whether it's the kind of exception that happens when calling a method on an undef, but will it be one of the calls you have here or is it somewhere deep down within one of the methods?
For me, I don't see that as a problem, either I want exceptions, or I want to ignore them
I doubt there exists a situation where I would want to ignore only this particular exception:
Can't call method "%" on an undefined value
But if there was, I'm sure I'd use one of cpan's exception filtering modules instead of ~>
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^4: What operator should perl5porters use for safe dereferencing?
by Jenda (Abbot) on May 31, 2012 at 14:33 UTC | |
by Anonymous Monk on Jun 01, 2012 at 02:53 UTC |