Skip to content

Instantly share code, notes, and snippets.

@dogbert17
Last active July 7, 2016 15:43
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save dogbert17/3f7c351762eefea9b97eb4746ffe4603 to your computer and use it in GitHub Desktop.
Save dogbert17/3f7c351762eefea9b97eb4746ffe4603 to your computer and use it in GitHub Desktop.
Attempt to document Capture.keys
=head2 method keys
Defined as:
multi method keys(Capture:D:) returns Seq:D
Usage:
$capture.keys
Returns a L<Seq|/type/Seq> containing all positional keys followed by all
named keys. For positional arguments the keys are the respective arguments
ordinal position starting from zero.
my $capture = \(2, 3, 5, apples => (red => 2));
say $capture.keys; # (0 1 2 apples)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment