summaryrefslogtreecommitdiff
path: root/av.h
diff options
context:
space:
mode:
authorNicholas Clark <nick@ccl4.org>2005-05-21 18:19:43 +0000
committerNicholas Clark <nick@ccl4.org>2005-05-21 18:19:43 +0000
commit7b2c381cf37e4e4611c4a864b5d6f7134344e3e6 (patch)
tree8807ac10b976a808e6707f79fbff58de3476795c /av.h
parent6e3207c2a1cd2d1644ac48e4d8ddd6742391e423 (diff)
downloadperl-7b2c381cf37e4e4611c4a864b5d6f7134344e3e6.tar.gz
Move the xpv_pv/xrv_rv member into the SV head, in a union with
IV and UV. Avoid allocating a body for IVs and RVs. p4raw-id: //depot/perl@24531
Diffstat (limited to 'av.h')
-rw-r--r--av.h3
1 files changed, 1 insertions, 2 deletions
diff --git a/av.h b/av.h
index c4711366f6..186ec35905 100644
--- a/av.h
+++ b/av.h
@@ -9,7 +9,6 @@
*/
struct xpvav {
- char* xav_array; /* pointer to first array element */
SSize_t xav_fill; /* Index of last element present */
SSize_t xav_max; /* max index for which array has space */
IV xof_off; /* ptr is incremented by offset */
@@ -56,7 +55,7 @@ Same as C<av_len()>. Deprecated, use C<av_len()> instead.
#define Nullav Null(AV*)
-#define AvARRAY(av) ((SV**)((XPVAV*) SvANY(av))->xav_array)
+#define AvARRAY(av) ((av)->sv_u.sv_array)
#define AvALLOC(av) ((XPVAV*) SvANY(av))->xav_alloc
#define AvMAX(av) ((XPVAV*) SvANY(av))->xav_max
#define AvFILLp(av) ((XPVAV*) SvANY(av))->xav_fill