fp = PerlIO_openn(aTHX_ type,mode,-1,0,0,NULL,num_svs,svp);
}
} /* !& */
+ if (!fp && type && *type && *type != ':' && !isIDFIRST(*type))
+ goto unknown_open_mode;
} /* IoTYPE_WRONLY */
else if (*type == IoTYPE_RDONLY) {
/*SUPPRESS 530*/
}
fp = PerlIO_openn(aTHX_ type,mode,-1,0,0,NULL,num_svs,svp);
}
+ if (!fp && type && *type && *type != ':' && !isIDFIRST(*type))
+ goto unknown_open_mode;
} /* IoTYPE_RDONLY */
else if ((num_svs && /* '-|...' or '...|' */
type[0] == IoTYPE_STD && type[1] == IoTYPE_PIPE) ||
$Is_VMS = $^O eq 'VMS';
$Is_MacOS = $^O eq 'MacOS';
-plan tests => 100;
+plan tests => 102;
my $Perl = which_perl();
like($@, qr/<\$fh3{...}> line 1\./, "autoviv fh lexical helem");
}
+SKIP: {
+ skip("This test uses perlio", 1) unless $Config{useperlio};
+ my $w;
+ use warnings 'layer';
+ local $SIG{__WARN__} = sub { $w = shift };
+
+ eval { open(F, ">>>", "afile") };
+ like($w, qr/perlio: invalid separator character '>' in layer spec/,
+ "bad open warning");
+ like($@, qr/Unknown open\(\) mode '>>>'/,
+ "bad open failure");
+}
+