summaryrefslogtreecommitdiff
path: root/ext/pcre/pcrelib/pcre_xclass.c
diff options
context:
space:
mode:
authorSVN Migration <svn@php.net>2008-12-03 20:30:45 +0000
committerSVN Migration <svn@php.net>2008-12-03 20:30:45 +0000
commit2876046398950e59c3b3c460e67e6fec7ff2ba3c (patch)
tree33b2b8b4b859960a6446ad19d0ada1c55f9cfcda /ext/pcre/pcrelib/pcre_xclass.c
parent3fb86b0b9e79e6a3312b694f30ee627e2e1b325c (diff)
downloadphp-git-php-5.3.0alpha2.tar.gz
This commit was manufactured by cvs2svn to create tag 'php_5_3_0alpha2'.php-5.3.0alpha2
Diffstat (limited to 'ext/pcre/pcrelib/pcre_xclass.c')
-rw-r--r--ext/pcre/pcrelib/pcre_xclass.c11
1 files changed, 6 insertions, 5 deletions
diff --git a/ext/pcre/pcrelib/pcre_xclass.c b/ext/pcre/pcrelib/pcre_xclass.c
index 5253b857ad..d22d9e6488 100644
--- a/ext/pcre/pcrelib/pcre_xclass.c
+++ b/ext/pcre/pcrelib/pcre_xclass.c
@@ -102,7 +102,8 @@ while ((t = *data++) != XCL_END)
#ifdef SUPPORT_UCP
else /* XCL_PROP & XCL_NOTPROP */
{
- const ucd_record * prop = GET_UCD(c);
+ int chartype, script;
+ int category = _pcre_ucp_findprop(c, &chartype, &script);
switch(*data)
{
@@ -111,20 +112,20 @@ while ((t = *data++) != XCL_END)
break;
case PT_LAMP:
- if ((prop->chartype == ucp_Lu || prop->chartype == ucp_Ll || prop->chartype == ucp_Lt) ==
+ if ((chartype == ucp_Lu || chartype == ucp_Ll || chartype == ucp_Lt) ==
(t == XCL_PROP)) return !negated;
break;
case PT_GC:
- if ((data[1] == _pcre_ucp_gentype[prop->chartype]) == (t == XCL_PROP)) return !negated;
+ if ((data[1] == category) == (t == XCL_PROP)) return !negated;
break;
case PT_PC:
- if ((data[1] == prop->chartype) == (t == XCL_PROP)) return !negated;
+ if ((data[1] == chartype) == (t == XCL_PROP)) return !negated;
break;
case PT_SC:
- if ((data[1] == prop->script) == (t == XCL_PROP)) return !negated;
+ if ((data[1] == script) == (t == XCL_PROP)) return !negated;
break;
/* This should never occur, but compilers may mutter if there is no