You assigned a array to a hash. This operation does a nice key - value kinda grouping of the array values. So your first re got a key and your second re got a value.
#!/usr/bin/perl
use strict;
my @array = (qr/^foo /, qr/bar$/);
print "@array\n";
my %hash = map {$_, 1} @array;
foreach (keys %hash) {
print "$_\n";
}