summaryrefslogtreecommitdiff
path: root/av.c
diff options
context:
space:
mode:
authorShlomi Fish <shlomif@iglu.org.il>2010-05-15 22:13:59 +0300
committerDavid Golden <dagolden@cpan.org>2010-05-25 12:15:01 -0400
commit71282cab69578876db765e8d8aadb9cc2331ebf2 (patch)
tree3e815240b4267ea9a0162b128283aebbf27a54bf /av.c
parent31bde0acd044dc2a6e4ccd40fa4660a6009fcb9d (diff)
downloadperl-71282cab69578876db765e8d8aadb9cc2331ebf2.tar.gz
Add a Perl equivalent to av_delete().
Signed-off-by: David Golden <dagolden@cpan.org>
Diffstat (limited to 'av.c')
-rw-r--r--av.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/av.c b/av.c
index 095147a3ee..f915fefbb8 100644
--- a/av.c
+++ b/av.c
@@ -791,7 +791,9 @@ Perl_av_fill(pTHX_ register AV *av, I32 fill)
Deletes the element indexed by C<key> from the array. Returns the
deleted element. If C<flags> equals C<G_DISCARD>, the element is freed
-and null is returned.
+and null is returned. Perl equivalent: C<my $elem = delete($myarray[$idx]);>
+for the non-C<G_DISCARD> version and a void-context C<delete($myarray[$idx]);>
+for the C<G_DISCARD> version.
=cut
*/