Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Fetching contributors…

Cannot retrieve contributors at this time

15 lines (12 sloc) 0.349 kB
use v6;
use Test;
plan 4;
#L<S03/"Smart matching"/Regex Hash hash key grep>
{
my %h = (moep => 'foo', bar => 'baz');
ok (/oep/ ~~ %h), 'Regex ~~ Hash (+,1)';
ok (/bar/ ~~ %h), 'Regex ~~ Hash (+,2)';
ok !(/ugh/ ~~ %h), 'Regex ~~ Hash (-,1)';
ok !(/foo/ ~~ %h), 'Regex ~~ Hash (-,value)';
}
# vim: ft=perl6
Jump to Line
Something went wrong with that request. Please try again.