Permalink
Browse files

Any numifies to 0

  • Loading branch information...
1 parent beb5018 commit 33ef6e6534be1cb10caa6e4c2b63b9ebd2375737 @sorear committed May 28, 2011
Showing with 4 additions and 0 deletions.
  1. +4 −0 lib/CORE.setting
View
@@ -48,6 +48,10 @@ my class Mu {
my class Any is Mu {
method flat() { @(self) }
+ method Numeric() {
+ die "Cannot use value like $.typename as a number" if defined(self);
+ 0;
+ }
method sort($cmp = &infix:<leg>) { @(self).sort($cmp) }
method first(Mu $filter) { for @(self) { return $_ if $_ ~~ $filter } }

0 comments on commit 33ef6e6

Please sign in to comment.