Skip to content

Instantly share code, notes, and snippets.

@gfldex
Created July 28, 2020 20:20
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 gfldex/1cbf85587e26beb8bbef465c5af4aff9 to your computer and use it in GitHub Desktop.
Save gfldex/1cbf85587e26beb8bbef465c5af4aff9 to your computer and use it in GitHub Desktop.
use v6;
class Exitcode does Positional {
has @.captured handles <elems AT-POS EXISTS-POS iterator>;
}
my $ex = Exitcode.new: :captured(<abc def ghi>);
say $ex[1];
say $ex ~~ /a/;
LEAVE slurp($*PROGRAM).say;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment