This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Switch most open() calls to three-argument form.
[perl5.git] / win32 / config_sh.PL
index 74e5f0d..c4a3112 100644 (file)
@@ -22,7 +22,7 @@ sub loadopts {
        shift @ARGV;
        my $optfile = shift @ARGV;
        local (*OPTF);
-       open OPTF, $optfile or die "Can't open $optfile: $!\n";
+       open OPTF, '<', $optfile or die "Can't open $optfile: $!\n";
        my @opts;
        chomp(my $line = <OPTF>);
        my @vars = split(/\t+~\t+/, $line);
@@ -59,7 +59,7 @@ $opt{known_extensions} = join(' ',FindExt::known_extensions()) || ' ';
 my $pl_h = '../patchlevel.h';
 
 if (-e $pl_h) {
-    open PL, "<$pl_h" or die "Can't open $pl_h: $!";
+    open PL, "<", $pl_h or die "Can't open $pl_h: $!";
     while (<PL>) {
        if (/^#\s*define\s+(PERL_\w+)\s+([\d.]+)/) {
            $opt{$1} = $2;