Re: is it utf8 or unicode?

[email protected] (Andreas J Koenig)
Newsgroups perl.unicode
Message-ID <[email protected]>
>>>>> On Wed, 09 Mar 2005 20:03:08 +0000, [email protected] said:

  > binmode FH1, ":raw";

Make this

   binmode FH1, ":utf8";

  > I don't understand what the [UTF8 "\x{c4}"]

"\x{x4}" is valid perl notation for the Unicode character 0xc4.

% perl -le '
my $data = "\xC4";
binmode STDOUT, ":utf8";
print $data ;
' | od -t x1
0000000 c3 84 0a
0000003

  > What's worse is that the output file contains xc4 and not
  > the utf-8 sequence I expected.

Because you chose :raw.

Hope this helps,
-- 
andreas
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.