Fix UV_SIZEOF to UVSIZE; change the overflow tests
[p5sagit/p5-mst-13.2.git] / t / pragma / warn / utf8
CommitLineData
0453d815 1
2 utf8.c AOK
3
4 All Mandatory warnings
5
6 [utf8_to_uv]
7 Malformed UTF-8 character
8 my $a = ord "\x80" ;
9
10 Malformed UTF-8 character
11 my $a = ord "\xf080" ;
12
13 [utf16_to_utf8]
14 Malformed UTF-16 surrogate
15 <<<<<< Add a test when somethig actually calls utf16_to_utf8
16
17__END__
767a6a26 18# utf8.c [utf8_to_uv]
0453d815 19use utf8 ;
20my $a = ord "\x80" ;
21EXPECT
22Malformed UTF-8 character at - line 3.
23########
767a6a26 24# utf8.c [utf8_to_uv]
0453d815 25use utf8 ;
26my $a = ord "\x80" ;
27{
4438c4b7 28 use warnings 'utf8' ;
0453d815 29 my $a = ord "\x80" ;
4438c4b7 30 no warnings 'utf8' ;
0453d815 31 my $a = ord "\x80" ;
32}
33EXPECT
34Malformed UTF-8 character at - line 3.
35\x80 will produce malformed UTF-8 character; use \x{80} for that at - line 6.
36Malformed UTF-8 character at - line 6.
37########
767a6a26 38# utf8.c [utf8_to_uv]
0453d815 39use utf8 ;
40my $a = ord "\xf080" ;
41EXPECT
42Malformed UTF-8 character at - line 3.
43########
767a6a26 44# utf8.c [utf8_to_uv]
0453d815 45use utf8 ;
46my $a = ord "\xf080" ;
47{
4438c4b7 48 use warnings 'utf8' ;
0453d815 49 my $a = ord "\xf080" ;
4438c4b7 50 no warnings 'utf8' ;
0453d815 51 my $a = ord "\xf080" ;
52}
53EXPECT
54Malformed UTF-8 character at - line 3.
55\xf0 will produce malformed UTF-8 character; use \x{f0} for that at - line 6.
56Malformed UTF-8 character at - line 6.