New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Filehandle capture confuses PerlIO layers #12320
Comments
From @xdgCreated by @xdgWhen Capture::Tiny saves, redirects and restores filehandles to capture output, use Encode; sub say { print @_, "\n" } my $foo = Encode::decode_utf8("\xC5\x82"); binmode( STDOUT, ":utf8" ); out('PRE'); sub out { ##### OUTPUT ##### Perl Info
|
From @xdgNote -- triggering this behavior requires Capture::Tiny 0.18 or earlier, Just because Capture::Tiny has a workaround does not resolve this issue. -- David |
@xdg - Status changed from 'new' to 'open' |
From @dmcbrideOn Monday August 6 2012 5:18:48 PM David Golden wrote:
This is a duplicate of https://rt-archive.perl.org/perl5/Ticket/Display.html?id=113982
You need to add ", output => 1" here: say "fd " . fileno(STDOUT) . " has " . join ', ', PerlIO::get_layers( Then you see the difference. Yes, I faced the same quandary with the previous (This may also mean that the fix/workaround to Capture::Tiny might be off in
|
From @xdgOn Mon, Aug 6, 2012 at 11:11 PM, Darin McBride <dmcbride@cpan.org> wrote:
I don't think it's quite the same, as this bug also points out that I've marked them as referring to each other, so whoever fixes it can -- David |
From @LeontOn Tue, Aug 7, 2012 at 6:11 AM, Darin McBride <dmcbride@cpan.org> wrote:
The layers shouldn't be different. binmode explicitly tries to make Leon |
From @LeontOn Tue, Aug 7, 2012 at 6:15 AM, David Golden <xdaveg@gmail.com> wrote:
I don't see how it's incorrect, it's just very confusing. Leon |
Migrated from rt.perl.org#114404 (status was 'open')
Searchable as RT114404$
The text was updated successfully, but these errors were encountered: