Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
use more modern FALLBACK instead of .^add_fallback
  • Loading branch information
lizmat committed May 9, 2015
1 parent 0b329a9 commit 20c3ae3
Showing 1 changed file with 3 additions and 6 deletions.
9 changes: 3 additions & 6 deletions src/core/Failure.pm
Expand Up @@ -29,15 +29,12 @@ my class Failure {
self.exception.message ~ "\n" ~ self.backtrace;
}

Failure.^add_fallback(
-> $, $ { True },
method ($name) {
$!exception.throw;
}
);
method sink() {
$!exception.throw($!backtrace) unless $!handled
}
method FALLBACK(*@_) {
$!exception.throw;
}
}

proto sub fail(|) {*};
Expand Down

0 comments on commit 20c3ae3

Please sign in to comment.