Don't expect ASCII ordering.
[p5sagit/p5-mst-13.2.git] / lib / encoding.t
CommitLineData
0a378802 1print "1..3\n";
2
3use encoding "latin1"; # ignored (overwritten by the next line)
4use encoding "greek";
5
6$a = "\xDF";
7$b = "\x{100}";
8
9my $c = $a . $b;
10
11# "greek" is "ISO 8859-7", and \xDF in ISO 8859-7 is
12# \x3AF in Unicode (GREEK SMALL LETTER IOTA WITH TONOS),
13# instead of \xDF in Unicode (LATIN SMALL LETTER SHARP S)
14
15print "not " unless ord($c) == 0x3af;
16print "ok 1\n";
17
18print "not " unless length($c) == 2;
19print "ok 2\n";
20
21print "not " unless ord(substr($c, 1, 1)) == 0x100;
22print "ok 3\n";
23
24