diff options
author | Nicholas Clark <nick@ccl4.org> | 2005-05-27 09:18:26 +0000 |
---|---|---|
committer | Nicholas Clark <nick@ccl4.org> | 2005-05-27 09:18:26 +0000 |
commit | 9b9d0b15bd9c5c0115200324ab9b04803069c7ce (patch) | |
tree | c511e92870e2a03c965812bc3304d8d554e7e1d4 /hv.h | |
parent | 62aa563719d028e176ee9e4eb16701b5a2193e4c (diff) | |
download | perl-9b9d0b15bd9c5c0115200324ab9b04803069c7ce.tar.gz |
Get the HEK once only in the hot code (class method calls)
p4raw-id: //depot/perl@24594
Diffstat (limited to 'hv.h')
-rw-r--r-- | hv.h | 2 |
1 files changed, 2 insertions, 0 deletions
@@ -227,6 +227,8 @@ C<SV*>. #define HvNAME(hv) HvNAME_get(hv) /* FIXME - all of these should use a UTF8 aware API, which should also involve getting the length. */ +/* This macro may go away without notice. */ +#define HvNAME_HEK(hv) (((XPVHV *)SvANY(hv))->xhv_aux && (((struct xpvhv_aux *)((XPVHV *)SvANY(hv))->xhv_aux)->xhv_name) ? ((struct xpvhv_aux *)((XPVHV *)SvANY(hv))->xhv_aux)->xhv_name: 0) #define HvNAME_get(hv) (((XPVHV *)SvANY(hv))->xhv_aux ? \ (((struct xpvhv_aux *)((XPVHV *)SvANY(hv))->xhv_aux)->xhv_name) ? HEK_KEY(((struct xpvhv_aux *)((XPVHV *)SvANY(hv))->xhv_aux)->xhv_name) : 0 : 0) #define HvNAMELEN_get(hv) (((XPVHV *)SvANY(hv))->xhv_aux ? \ |