programming-examples/perl/SystemFunction/The die function exits the Perl script and prints out an error message to STDERR.pl

7 lines
109 B
Perl
Raw Normal View History

2019-11-15 12:59:38 +01:00
#!/usr/bin/perl -w
$filename = "nofile";
open(TMP, $filename)
or die "Can't open \"$filename\"";