This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
av_fetch(): optimise the negative index branch.
authorDavid Mitchell <davem@iabyn.com>
Wed, 17 Aug 2016 08:59:06 +0000 (09:59 +0100)
committerDavid Mitchell <davem@iabyn.com>
Wed, 17 Aug 2016 12:38:56 +0000 (13:38 +0100)
commit93a3e97518c1f1e5d6916e1550a36f0d39d520e6
tree278d63c94a5514c3140f9dd796552240d1206204
parent1d7e6444bd515142acf34ef230b50f9d80ab9017
av_fetch(): optimise the negative index branch.

For a negative index one conditional is redundant, since after determining
that key < 0 and recomputing key as (AvFILLp(av) - key), key can't
be > AvFILLp(av).
av.c