summaryrefslogtreecommitdiff
path: root/t
diff options
context:
space:
mode:
authorYves Orton <demerphq@gmail.com>2009-09-02 17:37:48 +0200
committerYves Orton <demerphq@gmail.com>2009-09-02 18:02:40 +0200
commitba9ac1759cb6e7a5e6883c85edd0b450061b5ccb (patch)
tree4853570207d7e8c745fbaf5986915a341a74b6c0 /t
parentc6b4a156729e014eedc1d104dfb7b1a5d1a6e70e (diff)
downloadperl-ba9ac1759cb6e7a5e6883c85edd0b450061b5ccb.tar.gz
set PERL_LEGACY_UNICODE_CHARCLASS_MAPPINGS to 0 and enable proper POSIX char class matching
This also alters which Unicode properties that the POSIX character class and the Perl "special" character classes, like \w and \d map to. At the same time it allows a number of tests for POSIX character class behaviour to be switched from todo to non todo. Legacy testing is still available by changing the define and setting the PERL_TEST_LEGACY_POSIX_CC value to true.
Diffstat (limited to 't')
-rw-r--r--t/op/pat.t8
-rw-r--r--t/op/re_tests2
-rw-r--r--t/op/reg_posixcc.t2
3 files changed, 6 insertions, 6 deletions
diff --git a/t/op/pat.t b/t/op/pat.t
index 00c54902f4..c610a6a9b5 100644
--- a/t/op/pat.t
+++ b/t/op/pat.t
@@ -2061,11 +2061,11 @@ sub run_tests {
local $Message = "No SEGV in s/// and UTF-8";
my $s = "s#\x{100}" x 4;
ok $s =~ s/[^\w]/ /g;
- if ($ENV {REAL_POSIX_CC}) {
- iseq $s, "s " x 4;
+ if ( $ENV{PERL_TEST_LEGACY_POSIX_CC} ) {
+ iseq $s, "s \x{100}" x 4;
}
else {
- iseq $s, "s \x{100}" x 4;
+ iseq $s, "s " x 4;
}
}
@@ -4012,7 +4012,7 @@ sub run_tests {
};
skip "Eval failed ($@)", 1 if $@;
skip "PERL_LEGACY_UNICODE_CHARCLASS_MAPPINGS set to 0", 1
- if $ENV {REAL_POSIX_CC};
+ if !$ENV{PERL_TEST_LEGACY_POSIX_CC};
iseq join ('', @isPunctLatin1), '',
'IsPunct agrees with [:punct:] with explicit Latin1';
}
diff --git a/t/op/re_tests b/t/op/re_tests
index 10bee20f94..b9177e92ca 100644
--- a/t/op/re_tests
+++ b/t/op/re_tests
@@ -1387,7 +1387,7 @@ foo(\h)bar foo\tbar y $1 \t
# [perl #60344] Regex lookbehind failure after an (if)then|else in perl 5.10
/\A(?(?=db2)db2|\D+)(?<!processed)\.csv\z/xms sql_processed.csv n - -
/\N{U+0100}/ \x{100} y $& \x{100} # Bug #59328
-[\s][\S] \x{a0}\x{a0} nT - - # TODO Unicode complements should not match same character
+[\s][\S] \x{a0}\x{a0} n - - # Unicode complements should not match same character
# was generating malformed utf8
'[\x{100}\xff]'i \x{ff} y $& \x{ff}
diff --git a/t/op/reg_posixcc.t b/t/op/reg_posixcc.t
index df12063b3d..8b25d7de52 100644
--- a/t/op/reg_posixcc.t
+++ b/t/op/reg_posixcc.t
@@ -41,7 +41,7 @@ my @pats=(
"[:^space:]",
"[:blank:]",
"[:^blank:]" );
-if (not $ENV{REAL_POSIX_CC}) {
+if ($ENV{PERL_TEST_LEGACY_POSIX_CC}) {
$::TODO = "Only works under PERL_LEGACY_UNICODE_CHARCLASS_MAPPINGS = 0";
}