method handled

Documentation for method handled assembled from the following types:

class Failure

From Failure

(Failure) method handled

Defined as:

method handled(Failure:D: --> Bool:D)

Returns True for handled failures, False otherwise.

sub f() { fail }my $v = fsay $v.handled# OUTPUT: «False␤»

The handled method is an lvalue, which means you can also use it to set the handled state:

sub f() { fail }
my $v = f;
$v.handled = True;
say $v.handled# OUTPUT: «True␤»