diff options
author | Karl Williamson <public@khwilliamson.com> | 2011-12-25 14:42:06 -0700 |
---|---|---|
committer | Karl Williamson <public@khwilliamson.com> | 2011-12-25 15:54:53 -0700 |
commit | 2373c1b5d1361ab8bbe954fc8234512fd554e7e7 (patch) | |
tree | 2afe651cf23f3519c59047085e92a5c2d69c1d70 | |
parent | 316393f0b9d30be1862abb6ee1eed22bbaa8b55b (diff) | |
download | perl-khw/tricky.tar.gz |
re/reg_fold.t: Add and revise commentskhw/tricky
-rw-r--r-- | t/re/reg_fold.t | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/t/re/reg_fold.t b/t/re/reg_fold.t index 264b2fda4b..a4fe6fa63b 100644 --- a/t/re/reg_fold.t +++ b/t/re/reg_fold.t @@ -46,7 +46,8 @@ while (<$fh>) { # Try both Latin1 and Unicode for code points below 256 foreach my $upgrade ("", 'utf8::upgrade($c); ') { - if ($upgrade) { + if ($upgrade) { # No need to upgrade if already must be in + # utf8 next if $swap && $fold_above_latin1; next if !$swap && $cpv > 255; } @@ -98,7 +99,7 @@ for my $i (0x61 .. 0x7A, 0xE0 .. 0xF6, 0xF8 .. 0xFE) { $fold_ascii[$lower_ord] = $upper_ord; } -# Test every latin1 character that the correct values in both /u and /d +# Test every latin1 character for the correct values in both /u and /d for my $i (0 .. 255) { my $chr = sprintf "\\x%02X", $i; my $hex_fold_ascii = sprintf "0x%02X", $fold_ascii[$i]; |