This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
[perl #120826] correct documentation of sv parameter of call_sv()
authorTony Cook <tony@develop-help.com>
Mon, 3 Aug 2015 06:48:01 +0000 (16:48 +1000)
committerTony Cook <tony@develop-help.com>
Wed, 5 Aug 2015 04:37:51 +0000 (14:37 +1000)
perl.c

diff --git a/perl.c b/perl.c
index 1af5e29..1823c99 100644 (file)
--- a/perl.c
+++ b/perl.c
@@ -2664,8 +2664,22 @@ Perl_call_method(pTHX_ const char *methname, I32 flags)
 /*
 =for apidoc p||call_sv
 
 /*
 =for apidoc p||call_sv
 
-Performs a callback to the Perl sub whose name is in the SV.  See
-L<perlcall>.
+Performs a callback to the Perl sub specified by the SV.
+
+If neither the C<G_METHOD> or C<G_METHOD_NAMED> flag is supplied, the
+SV may be any of a CV, a GV, a reference to a CV, a reference to a GV
+or C<SvPV(sv)> will be used as the name of the sub to call.
+
+If the C<G_METHOD> flag is supplied, the SV may be a reference to a CV or
+C<SvPV(sv)> will be used as the name of the method to call.
+
+If the C<G_METHOD_NAMED> flag is supplied, C<SvPV(sv)> will be used as
+the name of the method to call.
+
+Some other values are treated specially for internal use and should
+not be depended on.
+
+See L<perlcall>.
 
 =cut
 */
 
 =cut
 */