Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
silly given/when
for @els -> $t {
my $f = False;
given $t.WHAT {
when Perl6::String::Interpolation { print "INTERPOLATION"; $f=True}
when Perl6::Bareword { print "BAREWORD"; $f=True }
}
say " ({$t.content})" if $f;
}
@renormalist

This comment has been minimized.

Copy link
Owner Author

commented Aug 12, 2017

            my $f = True;
            given $t.WHAT {
                when Perl6::String::Interpolation { print "INTERPOLATION" }
                when Perl6::Bareword { print "BAREWORD" }
                default { $f = False }
            }
            say " ({$t.content})" if $f;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.