http://www.perlmonks.org?node_id=454360


in reply to Re^3: Testing failures: How to override print to make it fail?
in thread Testing failures: How to override print to make it fail?

adding "or die" to print is kinda ... dumb.

That entirely depends on the application being developed. I've come across several apps where not checking for the result of print has caused some nasty and expensive intermittent bugs.

(Which is why I wish that print, open, read, etc. threw exceptions by default if called in a void context... Fixed in Perl 6 I think?)

Update: and

use Fatal qw( print );

won't work since print is one of those subroutines that Perl can't override cleanly.