summaryrefslogtreecommitdiff
path: root/av.c
diff options
context:
space:
mode:
Diffstat (limited to 'av.c')
-rw-r--r--av.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/av.c b/av.c
index e3c6d5a37c..21828a9254 100644
--- a/av.c
+++ b/av.c
@@ -272,8 +272,7 @@ Perl_av_fetch(pTHX_ AV *av, SSize_t key, I32 lval)
}
neg = (key < 0);
- /* XXX tmp restore old behaviour to make Variable::Magic pass */
- size = (neg ? AvFILL(av): AvFILLp(av)) + 1;
+ size = AvFILLp(av) + 1;
key += neg * size; /* handle negative index without using branch */
/* the cast from SSize_t to Size_t allows both (key < 0) and (key >= size)