RogersMine

 view release on metacpan or  search on metacpan

local/lib/perl5/x86_64-linux-thread-multi/Glib/GenPod.pm  view on Meta::CPAN


 =signature ($thing, @other) = $object->foo ($it, $something)

 Text in here is included in the generated documentation.
 You can actually include signature and arg directives
 at any point in this pod -- they are stripped after.
 In fact, any pod is valid in here, until the =cut.

 =cut
 void foo (...)
     PPCODE:
        /* crazy code follows */

=item =for arg name (type) description

=item =for arg name description

The arg directive adds or overrides an argument description.  The
description text is optional, as is the type specification (the part
in parentheses).  If you want to hide an argument, specify C<__hide__>
as its type.  The arg name does I<not> need to include a sigil,

local/lib/perl5/x86_64-linux-thread-multi/Glib/GenPod.pm  view on Meta::CPAN

		my @retnames = map { convert_return_type_to_name ($_) }
				@{ $xsub->{return_type} };
		unshift @outlist, @retnames;
	}
	my $retstr = @outlist
	           ? (@outlist > 1
		      ? "(".join (", ", @outlist).")"
		      : $outlist[0]
		     )." = "
		   : (defined $xsub->{codetype} and
		      $xsub->{codetype} eq 'PPCODE'
		      ? 'list = '
		      : ''
		     );
	
	"$retstr$call ".($argstr ? "($argstr)" : "");
}

=item $string = fixup_arg_name ($name)

Prepend a $ to anything that's not the literal ellipsis string '...'.

local/lib/perl5/x86_64-linux-thread-multi/Glib/ParseXSDoc.pm  view on Meta::CPAN

=item $xsub = $parser->parse_xsub (\@lines)

=item $xsub = $parser->parse_xsub (@lines)

Parse an xsub header, in the form of a list of lines,
into a data structure describing the xsub.  That includes
pulling out the argument types, aliases, and code type.

Without artificial intelligence, we cannot reliably 
determine anything about the types or number of parameters
returned from xsubs with PPCODE bodies.

OUTLIST parameters are pulled from the args list and put
into an "outlist" key.  IN_OUTLIST parameters are put into
both.

Data type names are not mangled at all.

Note that the method can take either a list of lines or a reference to a
list of lines.  The flat list form is provided for compatibility; the
reference form is preferred, to avoid duplicating a potentially large list

local/lib/perl5/x86_64-linux-thread-multi/Glib/ParseXSDoc.pm  view on Meta::CPAN

	}

	

	my $xstate = 'args';
	while ($_ = shift @thisxsub) {
		if (/^\s*ALIAS:/) {
			$xstate = 'alias';
		} elsif (/\s*(PREINIT|CLEANUP|OUTPUT|C_ARGS):/) {
			$xstate = 'code';
		} elsif (/\s*(PPCODE|CODE):/) {
			$xsub{codetype} = $1;
			last;
		} elsif ($xstate eq 'alias') {
			/^\s*([:\w]+)\s*=\s*(\d+)\s*$/;
			if (defined $2) {
				$xsub{alias}{$1} = $2;
			} else {
				warn "$filename:$lineno: WTF : seeking alias on line $_\n";
			}
		} elsif ($xstate eq 'args') {

local/man/man3/Glib::GenPod.3pm  view on Meta::CPAN

\&
\& =signature ($thing, @other) = $object\->foo ($it, $something)
\&
\& Text in here is included in the generated documentation.
\& You can actually include signature and arg directives
\& at any point in this pod \-\- they are stripped after.
\& In fact, any pod is valid in here, until the =cut.
\&
\& =cut
\& void foo (...)
\&     PPCODE:
\&        /* crazy code follows */
.Ve
.IP "=for arg name (type) description" 4
.IX Item "=for arg name (type) description"
.PD 0
.IP "=for arg name description" 4
.IX Item "=for arg name description"
.PD
The arg directive adds or overrides an argument description.  The
description text is optional, as is the type specification (the part

local/man/man3/Glib::ParseXSDoc.3pm  view on Meta::CPAN

.ie n .IP "$xsub = $parser\->parse_xsub (@lines)" 4
.el .IP "\f(CW$xsub\fR = \f(CW$parser\fR\->parse_xsub (@lines)" 4
.IX Item "$xsub = $parser->parse_xsub (@lines)"
.PD
Parse an xsub header, in the form of a list of lines,
into a data structure describing the xsub.  That includes
pulling out the argument types, aliases, and code type.
.Sp
Without artificial intelligence, we cannot reliably 
determine anything about the types or number of parameters
returned from xsubs with \s-1PPCODE\s0 bodies.
.Sp
\&\s-1OUTLIST\s0 parameters are pulled from the args list and put
into an \*(L"outlist\*(R" key.  \s-1IN_OUTLIST\s0 parameters are put into
both.
.Sp
Data type names are not mangled at all.
.Sp
Note that the method can take either a list of lines or a reference to a
list of lines.  The flat list form is provided for compatibility; the
reference form is preferred, to avoid duplicating a potentially large list



( run in 0.852 second using v1.01-cache-2.11-cpan-5511b514fd6 )