Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Merge pull request #272 from donaldh/parrot_io
Remove some more parrot specifics in IO.pm
  • Loading branch information
FROGGS committed May 28, 2014
2 parents ac74318 + 0a5072c commit 42cd53f
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 19 deletions.
19 changes: 1 addition & 18 deletions src/core/IO.pm
Expand Up @@ -261,17 +261,7 @@ my class IO::Handle does IO::FileTestable {
}

method write(IO::Handle:D: Blob:D $buf) {
#?if parrot
# This relies on the Parrot 'binary' encoding and that nqp::decode
# passes encoding straight down to Parrot.
my str $encoding = $!PIO.encoding;
$!PIO.encoding('binary');
$!PIO.print(nqp::decode(nqp::decont($buf), 'binary'));
$!PIO.encoding($encoding) unless $encoding eq 'binary';
#?endif
#?if !parrot
nqp::writefh($!PIO, nqp::decont($buf));
#?endif
True;
}

Expand Down Expand Up @@ -724,14 +714,7 @@ multi sub spurt(Cool $filename,
proto sub cwd(|) { * }
multi sub cwd() {
return nqp::p6box_s(
#?if parrot
pir::trans_encoding__Ssi(
nqp::cwd(),
pir::find_encoding__Is('utf8'))
#?endif
#?if !parrot
nqp::cwd(),
#?endif
nqp::cwd()
);
CATCH {
default {
Expand Down
2 changes: 1 addition & 1 deletion tools/build/NQP_REVISION
@@ -1 +1 @@
2014.05-1-gb436340
2014.05-4-g6cc7d6e

0 comments on commit 42cd53f

Please sign in to comment.