diff options
author | Nicholas Clark <nick@ccl4.org> | 2005-05-29 19:35:38 +0000 |
---|---|---|
committer | Nicholas Clark <nick@ccl4.org> | 2005-05-29 19:35:38 +0000 |
commit | a3874608cd3bf4e33ccd66b8bb03b2aeda20af14 (patch) | |
tree | 1dd180911ed35cffcf3ddf5a647ffaa26a16c150 /pp.c | |
parent | 345d1b6f8b9605e2699c84cc5fc9a99a40bc982a (diff) | |
download | perl-a3874608cd3bf4e33ccd66b8bb03b2aeda20af14.tar.gz |
Goodbye xav_arylen. You won't be missed that much.
So now there's a buy 5 get one free offer on PVAV bodies.
p4raw-id: //depot/perl@24619
Diffstat (limited to 'pp.c')
-rw-r--r-- | pp.c | 12 |
1 files changed, 6 insertions, 6 deletions
@@ -295,13 +295,13 @@ PP(pp_av2arylen) { dSP; AV *av = (AV*)TOPs; - SV *sv = AvARYLEN(av); - if (!sv) { - AvARYLEN(av) = sv = NEWSV(0,0); - sv_upgrade(sv, SVt_IV); - sv_magic(sv, (SV*)av, PERL_MAGIC_arylen, Nullch, 0); + SV **sv = Perl_av_arylen_p(aTHX_ (AV*)av); + if (!*sv) { + *sv = NEWSV(0,0); + sv_upgrade(*sv, SVt_PVMG); + sv_magic(*sv, (SV*)av, PERL_MAGIC_arylen, Nullch, 0); } - SETs(sv); + SETs(*sv); RETURN; } |