Skip to content

Commit

Permalink
fix .pick and .roll on enums
Browse files Browse the repository at this point in the history
  • Loading branch information
moritz committed Sep 22, 2010
1 parent 750a024 commit 8156beb
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/glue/enum.pm
Expand Up @@ -8,8 +8,8 @@ our sub SETUP_NAMED_ENUM($name, $values) {
method WHAT { $enumeration-object }
method enums { $values }
method Str { $name }
multi method pick(:$replace) { $values.pick($replace) }
multi method pick($num, :$replace) { $values.pick($num, $replace) }
multi method roll($num = 1) { $values.roll($num) }
multi method pick($num = 1) { $values.pick($num) }
method ACCEPTS($topic) { $topic eqv any $values.values }
});
pir::set_hll_global__vPSP(@base_ns, $shortname, $enumeration-object);
Expand Down

2 comments on commit 8156beb

@colomon
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

moritz++ -- sorry I missed these!

@Daenyth
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I read the commit message as .rick and .roll. It was much more entertaining that way :)

Please sign in to comment.