Skip to content

Commit

Permalink
Teach Hash's STORE about Enum (and thus Pair).
Browse files Browse the repository at this point in the history
  • Loading branch information
jnthn committed Feb 6, 2010
1 parent 0a9c12d commit 815a825
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/core/Hash.pm
Expand Up @@ -31,7 +31,9 @@ role Hash is EnumMap {
}
else {
given $cur {
# when Enum { ... }
when Enum {
self{$cur.key} = $cur.value;
}
# when EnumMap { ... }
default {
$key = $cur;
Expand Down

0 comments on commit 815a825

Please sign in to comment.