X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=pod%2Fperlebcdic.pod;h=942526b0e937c378d234fccfcec2f76c612a0700;hb=075502290ff69af888b5629ff1fecf91d588fbbd;hp=0305b6b323236f5d07d89e050f3ef3bd6fa3c72a;hpb=aa2b82fcd287c16c76ad7206bc32889229a2f2ec;p=p5sagit%2Fp5-mst-13.2.git diff --git a/pod/perlebcdic.pod b/pod/perlebcdic.pod index 0305b6b..942526b 100644 --- a/pod/perlebcdic.pod +++ b/pod/perlebcdic.pod @@ -664,13 +664,13 @@ it in tr/// like so: '\060\061\062\063\064\065\066\067\070\071\263\333\334\331\332\237' ; my $ebcdic_string = $ascii_string; - eval '$ebcdic_string =~ tr/\000-\377/' . $cp_037 . '/'; + eval '$ebcdic_string =~ tr/' . $cp_037 . '/\000-\377/'; To convert from EBCDIC 037 to ASCII just reverse the order of the tr/// arguments like so: my $ascii_string = $ebcdic_string; - eval '$ascii_string = tr/' . $cp_037 . '/\000-\377/'; + eval '$ascii_string =~ tr/\000-\377/' . $cp_037 . '/'; Similarly one could take the output of the third column from recipe 0 to obtain a C<$cp_1047> table. The fourth column of the output from recipe