Use C<:encoding(ENCODING)> either in open() or binmode() to install
a layer that does transparently character set and encoding transformations,
-for example from Shift-JIS to Unicode. Note that an C<:encoding> also
-enables C<:utf8>. See L<PerlIO::encoding> for more information.
+for example from Shift-JIS to Unicode. Note that under C<stdio>
+an C<:encoding> also enables C<:utf8>. See L<PerlIO::encoding>
+for more information.
=item :via
my @layers = PerlIO::get_layers(FH);
The layers are returned in the order an open() or binmode() call would
-use them. Note that the stack begings (normally) from C<stdio>, the
-platform specific low-level I/O (like C<unix>) is not part of the stack.
+use them. Note that the stack begins (normally) from C<stdio> or from
+C<perlio>. Under C<stdio> the platform specific low-level I/O (like
+C<unix>) is not part of the stack, but under C<perlio> it is.
By default the layers from the input side of the filehandle is
returned, to get the output side use the optional C<output> argument:
print "1..0 # Skip: not perlio\n";
exit 0;
}
+ if (exists $ENV{PERLIO} && $ENV{PERLIO} ne 'stdio') {
+ print "1..0 # PERLIO non-stdio\n";
+ exit(0);
+ }
}
plan tests => 43;