Skip to content

Commit

Permalink
Ensure we run &THE_END when using custom Exception handler
Browse files Browse the repository at this point in the history
Fixes lack of deprecation warning for RAKUDO_EXCEPTIONS_HANDLER env var
  • Loading branch information
zoffixznet committed Jul 29, 2018
1 parent 5e1df41 commit d2116ef
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions src/core/Exception.pm6
Expand Up @@ -369,14 +369,18 @@ do {
my $class := ::("Exceptions::$handler");
unless nqp::istype($class,Failure) {
temp %*ENV<RAKUDO_EXCEPTIONS_HANDLER> = ""; # prevent looping
return unless $class.process($e)
my $res := $class.process($e);
nqp::getcurhllsym('&THE_END')();
return unless $res;
}
}
if %*ENV<PERL6_EXCEPTIONS_HANDLER> -> $handler {
my $class := ::("Exceptions::$handler");
unless nqp::istype($class,Failure) {
temp %*ENV<PERL6_EXCEPTIONS_HANDLER> = ""; # prevent looping
return unless $class.process($e)
my $res := $class.process($e);
nqp::getcurhllsym('&THE_END')();
return unless $res;
}
}

Expand Down

0 comments on commit d2116ef

Please sign in to comment.