Skip to content

Commit 7c9ae89

Browse files
committed
[Parameter] explain how to obtain an Parameter object; link to Signature
1 parent d57507b commit 7c9ae89

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

lib/Parameter.pod

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,16 @@
66
77
Represents a parameter, for purpose of introspection.
88
9+
The usual way to obtain a Parameter object is to create a signature,
10+
and call C<.params> on it to obtain a list of the Parameters.
11+
12+
my $sig = :(Str $x);
13+
my $param = $sig.params[0];
14+
say $sig.type; # Str()
15+
16+
See L<Signature> for more information, and also for an explanation
17+
on what most of the concepts related to parameters mean.
18+
919
=head1 Methods
1020
1121
=head2 name

0 commit comments

Comments
 (0)