summaryrefslogtreecommitdiff
path: root/pod/perluniintro.pod
diff options
context:
space:
mode:
authorJarkko Hietaniemi <jhi@iki.fi>2002-10-20 18:48:09 +0300
committerRafael Garcia-Suarez <rgarciasuarez@gmail.com>2002-10-22 18:48:00 +0000
commitc722ef0a9de73f0b0b48ec98b598b2cc10421bc5 (patch)
treece620368fa0c954223a4f38bcb51f628e70b19db /pod/perluniintro.pod
parentf3548bdc4d2efd11e139d110e60764b9dae81319 (diff)
downloadperl-c722ef0a9de73f0b0b48ec98b598b2cc10421bc5.tar.gz
perluniintro
Message-ID: <20021020124809.GE444369@lyta.hut.fi> p4raw-id: //depot/perl@18049
Diffstat (limited to 'pod/perluniintro.pod')
-rw-r--r--pod/perluniintro.pod7
1 files changed, 4 insertions, 3 deletions
diff --git a/pod/perluniintro.pod b/pod/perluniintro.pod
index 223dbae7fd..c2a57d8888 100644
--- a/pod/perluniintro.pod
+++ b/pod/perluniintro.pod
@@ -398,9 +398,10 @@ written to the stream. For example, the following snippet copies the
contents of the file "text.jis" (encoded as ISO-2022-JP, aka JIS) to
the file "text.utf8", encoded as UTF-8:
- open(my $nihongo, '<:encoding(iso2022-jp)', 'text.jis');
- open(my $unicode, '>:utf8', 'text.utf8');
- while (<$nihongo>) { print $unicode }
+ open(my $nihongo, '<:encoding(iso-2022-jp)', 'text.jis');
+ open(my $unicode, '>:utf8', 'text.utf8');
+ select $unicode;
+ while (<$nihongo>) { print }
The naming of encodings, both by the C<open()> and by the C<open>
pragma, is similar to the C<encoding> pragma in that it allows for