summaryrefslogtreecommitdiff
path: root/pp_pack.c
diff options
context:
space:
mode:
authorKarl Williamson <public@khwilliamson.com>2012-12-06 11:31:19 -0700
committerKarl Williamson <public@khwilliamson.com>2012-12-09 09:47:18 -0700
commit76a77b1b5dc44d6f70bf59fdc331a1332081b301 (patch)
treedb8475e1f023fe4cb73ebd33e0fd4508686d5bda /pp_pack.c
parent009ccfeda269d5b353a297ca4059497343c8ce41 (diff)
downloadperl-76a77b1b5dc44d6f70bf59fdc331a1332081b301.tar.gz
pp.c pp_pack.c: Use macro instead of function
This converts to use is_SPACE_utf8() instead of the (soon to be deprecated) is_utf8_space(). The macro is faster, avoiding the function call completely, so the performance need to make a special case for a SPACE character is gone.
Diffstat (limited to 'pp_pack.c')
-rw-r--r--pp_pack.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/pp_pack.c b/pp_pack.c
index a2a5c68847..321a47dbf7 100644
--- a/pp_pack.c
+++ b/pp_pack.c
@@ -1470,7 +1470,7 @@ S_unpack_rec(pTHX_ tempsym_t* symptr, const char *s, const char *strbeg, const c
if (utf8 && (symptr->flags & FLAG_WAS_UTF8)) {
for (ptr = s+len-1; ptr >= s; ptr--)
if (*ptr != 0 && !UTF8_IS_CONTINUATION(*ptr) &&
- !is_utf8_space((U8 *) ptr)) break;
+ !isSPACE_utf8(ptr)) break;
if (ptr >= s) ptr += UTF8SKIP(ptr);
else ptr++;
if (ptr > s+len)