open(my $fh, ">", \my $text); $decoder->decode(\*DATA, $fh); print "decoded text = $text\n";