Skip to content

Instantly share code, notes, and snippets.

@jnthn
Created May 16, 2013 21:19
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jnthn/5595193 to your computer and use it in GitHub Desktop.
Save jnthn/5595193 to your computer and use it in GitHub Desktop.
diff --git a/src/core/Hash.pm b/src/core/Hash.pm
index 54d7881..0aaced6 100644
--- a/src/core/Hash.pm
+++ b/src/core/Hash.pm
@@ -114,7 +114,7 @@ my class Hash {
}
my role TypedHash[::TValue] does Associative[TValue] {
- method at_key($key is copy, TValue $v? is copy) is rw {
+ method at_key(::?CLASS:D: $key is copy, TValue $v? is copy) is rw {
$key = $key.Str;
self.exists($key)
?? nqp::findmethod(EnumMap, 'at_key')(self, $key)
@@ -135,7 +135,7 @@ my class Hash {
}
my role TypedHash[::TValue, ::TKey] does Associative[TValue] {
has $!keys;
- method at_key(TKey \key, TValue $v? is copy) is rw {
+ method at_key(::?CLASS:D: TKey \key, TValue $v? is copy) is rw {
my $key_which = key.WHICH;
self.exists($key_which)
?? nqp::findmethod(EnumMap, 'at_key')(self, $key_which)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment