summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Mitchell <davem@iabyn.com>2011-05-31 13:45:55 +0100
committerDavid Mitchell <davem@iabyn.com>2011-05-31 13:45:55 +0100
commitddd2cc91d6090d4bcc45a8bb113437dd58fd2335 (patch)
tree1a107b6b022ed5bfdebc0662c2aa9358422ef1f8
parenta0aa6076c554bfbd5053136f26077d9c58b3526e (diff)
downloadperl-ddd2cc91d6090d4bcc45a8bb113437dd58fd2335.tar.gz
[perl #91790] Perlguts documentation for sv_setref_pv
The section of documentation in perlguts for the sv_setref_* functions was ambiguous: it wasn't clear whether each paragraph was referring to the function above or below it. Fix this by prepending lots of "The following function...". Also fix a couple of functions signatures.
-rw-r--r--pod/perlguts.pod38
1 files changed, 21 insertions, 17 deletions
diff --git a/pod/perlguts.pod b/pod/perlguts.pod
index 21f827a9de..e77d6b8fea 100644
--- a/pod/perlguts.pod
+++ b/pod/perlguts.pod
@@ -619,41 +619,45 @@ L<Stashes and Globs> for information on converting class names into stashes.
/* Still under construction */
-Upgrades rv to reference if not already one. Creates new SV for rv to
-point to. If C<classname> is non-null, the SV is blessed into the specified
-class. SV is returned.
+The following function upgrades rv to reference if not already one.
+Creates a new SV for rv to point to. If C<classname> is non-null, the SV
+is blessed into the specified class. SV is returned.
SV* newSVrv(SV* rv, const char* classname);
-Copies integer, unsigned integer or double into an SV whose reference is C<rv>. SV is blessed
-if C<classname> is non-null.
+The following three functions copy integer, unsigned integer or double
+into an SV whose reference is C<rv>. SV is blessed if C<classname> is
+non-null.
SV* sv_setref_iv(SV* rv, const char* classname, IV iv);
SV* sv_setref_uv(SV* rv, const char* classname, UV uv);
SV* sv_setref_nv(SV* rv, const char* classname, NV iv);
-Copies the pointer value (I<the address, not the string!>) into an SV whose
-reference is rv. SV is blessed if C<classname> is non-null.
+The following function copies the pointer value (I<the address, not the
+string!>) into an SV whose reference is rv. SV is blessed if C<classname>
+is non-null.
- SV* sv_setref_pv(SV* rv, const char* classname, PV iv);
+ SV* sv_setref_pv(SV* rv, const char* classname, void* pv);
-Copies string into an SV whose reference is C<rv>. Set length to 0 to let
-Perl calculate the string length. SV is blessed if C<classname> is non-null.
+The following function copies string into an SV whose reference is C<rv>.
+Set length to 0 to let Perl calculate the string length. SV is blessed if
+C<classname> is non-null.
- SV* sv_setref_pvn(SV* rv, const char* classname, PV iv, STRLEN length);
+ SV* sv_setref_pvn(SV* rv, const char* classname, char* pv, STRLEN length);
-Tests whether the SV is blessed into the specified class. It does not
-check inheritance relationships.
+The following function tests whether the SV is blessed into the specified
+class. It does not check inheritance relationships.
int sv_isa(SV* sv, const char* name);
-Tests whether the SV is a reference to a blessed object.
+The following function tests whether the SV is a reference to a blessed object.
int sv_isobject(SV* sv);
-Tests whether the SV is derived from the specified class. SV can be either
-a reference to a blessed object or a string containing a class name. This
-is the function implementing the C<UNIVERSAL::isa> functionality.
+The following function tests whether the SV is derived from the specified
+class. SV can be either a reference to a blessed object or a string
+containing a class name. This is the function implementing the
+C<UNIVERSAL::isa> functionality.
bool sv_derived_from(SV* sv, const char* name);