in reply to Re^5: Initial Devel::UncheckedOps, a macro for perl
in thread Initial Devel::UncheckedOps, a macro for perl
I think you were thinking of throwing errors on STDOUT not being a valid handle. If someone had closed it before or something. This generalizes the error checking to any error including such favorites as ENOSPC. It'll still throw errors if the handle being written to isn't valid. Heck, this is how I did most of my testing - checking against a print to an invalid handle. It was too inconvenient to keep a full file system around just for testing.
print BAR "Hi!" or die $!; # Bad file descriptor at ...
|
|---|