Documentation for method nice assembled from the following pages:
Class: Backtrace §
From Backtrace
(Backtrace) method nice §
Defined as:
method nice(Backtrace:D: :$oneline)
Returns the backtrace as a list of interesting frames. If :$oneline is set, will stop after the first frame.
sub zipi { { { die "Something bad happened" }() }() };
try zipi; say $!.backtrace.nice( :oneline ) if $!; # OUTPUT: « in sub zipi at /tmp/... line 1»
try zipi; say $!.backtrace.nice( :oneline ) if $!; # OUTPUT: « in sub zipi at /tmp/... line 1»