in reply to utf8 output with 5.8
Note that \x.. (no {} and only two hexadecimal digits), \x{...}, and chr(...) for arguments less than 0x100 (decimal 256) generate an eight-bit character for backward compatibility with older Perls. For arguments of 0x100 or more, Unicode characters are always produced. If you want to force the production of Unicode characters regardless of the numeric value, use pack("U", ...) instead of \x.., \x{...}, or chr().
This explains why "\x{f6}" won't produce utf8 output.
Nonetheless the pack( "U", hex( "f6" ) ) I used
originally should spit out a two byte sequence, shouldn't it?
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: Re: utf8 output with 5.8
by axelrose (Scribe) on Nov 26, 2002 at 17:18 UTC |