summaryrefslogtreecommitdiff
path: root/regcomp.sym
diff options
context:
space:
mode:
authorKarl Williamson <khw@cpan.org>2018-12-06 17:18:25 -0700
committerKarl Williamson <khw@cpan.org>2018-12-26 12:50:38 -0700
commitc316b824875fdd5ce52338f301fb0255d843dfec (patch)
treec713f631b889cca26e22cadb97523733b14b7c8b /regcomp.sym
parentb2296192536090829ba6d2cb367456f4e346dcc6 (diff)
downloadperl-c316b824875fdd5ce52338f301fb0255d843dfec.tar.gz
Add new regnode: ANYOFH, without a bitmap
This commit adds a regnode for the case where nothing in the bit map has matches. This allows the bitmap to be omitted, saving 32 bytes of otherwise wasted space per node. Many non-Latin Unicode properties have this characteristic. Further, since this node applies only to code points above 255, which are representable only in UTF-8, we can trivially fail a match where the target string isn't in UTF-8. Time savings also accrue from skipping the bitmap look-up. When swashes are removed, even more time will be saved.
Diffstat (limited to 'regcomp.sym')
-rw-r--r--regcomp.sym1
1 files changed, 1 insertions, 0 deletions
diff --git a/regcomp.sym b/regcomp.sym
index 25008905a8..d48d57e286 100644
--- a/regcomp.sym
+++ b/regcomp.sym
@@ -62,6 +62,7 @@ ANYOF ANYOF, sv charclass S ; Match character in (or not in) this
ANYOFD ANYOF, sv charclass S ; Like ANYOF, but /d is in effect
ANYOFL ANYOF, sv charclass S ; Like ANYOF, but /l is in effect
ANYOFPOSIXL ANYOF, sv charclass_posixl S ; Like ANYOFL, but matches [[:posix:]] classes
+ANYOFH ANYOF, sv 1 S ; Like ANYOF, but only has "High" matches, none in the bitmap
ANYOFM ANYOFM byte 1 S ; Like ANYOF, but matches an invariant byte as determined by the mask and arg
NANYOFM ANYOFM byte 1 S ; complement of ANYOFM