Commit | Line | Data |
0a378802 |
1 | print "1..3\n"; |
2 | |
3 | use encoding "latin1"; # ignored (overwritten by the next line) |
4 | use encoding "greek"; |
5 | |
6 | $a = "\xDF"; |
7 | $b = "\x{100}"; |
8 | |
9 | my $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 | |
15 | print "not " unless ord($c) == 0x3af; |
16 | print "ok 1\n"; |
17 | |
18 | print "not " unless length($c) == 2; |
19 | print "ok 2\n"; |
20 | |
21 | print "not " unless ord(substr($c, 1, 1)) == 0x100; |
22 | print "ok 3\n"; |
23 | |
24 | |