4 unless(grep /blib/, @INC) {
13 use charnames ':full';
15 print "not " unless "Here\N{EXCLAMATION MARK}?" eq "Here\041?";
19 use bytes; # TEST -utf8 can switch utf8 on
21 print "# \$res=$res \$\@='$@'\nnot "
22 if $res = eval <<'EOE'
23 use charnames ":full";
24 "Here: \N{CYRILLIC SMALL LETTER BE}!";
27 or $@ !~ /above 0xFF/;
29 # print "# \$res=$res \$\@='$@'\n";
31 print "# \$res=$res \$\@='$@'\nnot "
32 if $res = eval <<'EOE'
33 use charnames 'cyrillic';
37 or $@ !~ /CYRILLIC CAPITAL LETTER BE.*above 0xFF/;
41 # If octal representation of unicode char is \0xyzt, then the utf8 is \3xy\2zt
42 $encoded_be = "\320\261";
43 $encoded_alpha = "\316\261";
44 $encoded_bet = "\327\221";
45 $encoded_deseng = "\360\220\221\215";
52 use charnames ':full';
54 print "not " unless to_bytes("\N{CYRILLIC SMALL LETTER BE}") eq $encoded_be;
57 use charnames qw(cyrillic greek :short);
59 print "not " unless to_bytes("\N{be},\N{alpha},\N{hebrew:bet}")
60 eq "$encoded_be,$encoded_alpha,$encoded_bet";
65 use charnames ':full';
67 print "not " unless "\x{263a}" eq "\N{WHITE SMILING FACE}";
69 print "not " unless length("\x{263a}") == 1;
71 print "not " unless length("\N{WHITE SMILING FACE}") == 1;
73 print "not " unless sprintf("%vx", "\x{263a}") eq "263a";
75 print "not " unless sprintf("%vx", "\N{WHITE SMILING FACE}") eq "263a";
77 print "not " unless sprintf("%vx", "\xFF\N{WHITE SMILING FACE}") eq "ff.263a";
79 print "not " unless sprintf("%vx", "\x{ff}\N{WHITE SMILING FACE}") eq "ff.263a";
84 use charnames qw(:full);
87 my $named = "\N{CUBE ROOT}";
89 print "not " unless ord($x) == ord($named);
94 use charnames qw(:full);
96 print "not " unless "\x{100}\N{CENT SIGN}" eq "\x{100}"."\N{CENT SIGN}";
101 use charnames ':full';
104 unless to_bytes("\N{DESERET SMALL LETTER ENG}") eq $encoded_deseng;
111 use charnames ':full';
114 unless "\N{U+263A}" eq "\N{WHITE SMILING FACE}";