diff options
author | Karl Williamson <khw@cpan.org> | 2018-08-20 18:31:04 -0600 |
---|---|---|
committer | Karl Williamson <khw@cpan.org> | 2019-02-14 22:12:44 -0700 |
commit | 73b95840bb1b55d761ec2dd075d2a8c37fa94bf4 (patch) | |
tree | 62173297f7046b6354f4a4275ed45ceb3d81c86c /t | |
parent | dd52e3cc434f4c6a495379f06a99d35da217eecb (diff) | |
download | perl-73b95840bb1b55d761ec2dd075d2a8c37fa94bf4.tar.gz |
Move \p{user-defined} to core from utf8_heavy.pl
This large commit moves the handling of user-defined properties to C
code. This should speed it up, but the main reason to do this is to
stop using swashes in this case, leaving only tr/// using them. Once
that too is converted, all swash handling can be ripped out of perl.
Doing this in perl has caused some nasty interactions that will now be
fixed automatically.
The change is not entirely transparent, however (besides speed and the
possibility of removing these interactions). perldelta in this commit
details these.
Diffstat (limited to 't')
-rw-r--r-- | t/op/taint.t | 2 | ||||
-rw-r--r-- | t/re/anyof.t | 10 |
2 files changed, 6 insertions, 6 deletions
diff --git a/t/op/taint.t b/t/op/taint.t index 9edaa55b03..adb6907a45 100644 --- a/t/op/taint.t +++ b/t/op/taint.t @@ -2378,7 +2378,7 @@ end ok("A" =~ /\p{$prop}/, "user-defined property: non-tainted case"); $prop = "IsA$TAINT"; eval { "A" =~ /\p{$prop}/}; - like($@, qr/Insecure user-defined property \\p\{main::IsA\}/, + like($@, qr/Insecure user-defined property "IsA" in regex/, "user-defined property: tainted case"); } diff --git a/t/re/anyof.t b/t/re/anyof.t index 3656224eb1..f8be0eec31 100644 --- a/t/re/anyof.t +++ b/t/re/anyof.t @@ -468,11 +468,11 @@ my @tests = ( '\P{All}' => 'OPFAIL', '[\p{Any}]' => 'ANYOF[\x00-\xFF][0100-10FFFF]', - '[\p{IsMyRuntimeProperty}]' => 'ANYOF[+utf8::IsMyRuntimeProperty]', - '[^\p{IsMyRuntimeProperty}]' => 'ANYOF[^{+utf8::IsMyRuntimeProperty}]', - '[a\p{IsMyRuntimeProperty}]' => 'ANYOF[a][+utf8::IsMyRuntimeProperty]', - '[^a\p{IsMyRuntimeProperty}]' => 'ANYOF[^a{+utf8::IsMyRuntimeProperty}]', - '[^a\x{100}\p{IsMyRuntimeProperty}]' => 'ANYOF[^a{+utf8::IsMyRuntimeProperty}0100]', + '[\p{IsMyRuntimeProperty}]' => 'ANYOF[+main::IsMyRuntimeProperty]', + '[^\p{IsMyRuntimeProperty}]' => 'ANYOF[^{+main::IsMyRuntimeProperty}]', + '[a\p{IsMyRuntimeProperty}]' => 'ANYOF[a][+main::IsMyRuntimeProperty]', + '[^a\p{IsMyRuntimeProperty}]' => 'ANYOF[^a{+main::IsMyRuntimeProperty}]', + '[^a\x{100}\p{IsMyRuntimeProperty}]' => 'ANYOF[^a{+main::IsMyRuntimeProperty}0100]', '[^\p{All}\p{IsMyRuntimeProperty}]' => 'OPFAIL', '[\p{All}\p{IsMyRuntimeProperty}]' => 'SANY', |