Single frame of a Backtrace
A single backtrace frame. It identifies a location in the source code.
method file(Backtrace::Frame --> Str)
Returns the file name.
my = Backtrace.new;my = [0];say .file;
method line(Backtrace::Frame --> Int)
Returns the line number (line numbers start counting from 1).
my = Backtrace.new;my = [0];say .line;
method code(Backtrace::Frame)
Returns the code object into which .file
and .line
point, if available.
my = Backtrace.new;my = [0];say .code;
method subname(Backtrace::Frame --> Str)
Returns the name of the enclosing subroutine.
my = Backtrace.new;my = [0];say .subname;
method is-hidden(Backtrace::Frame: --> Bool)
Returns True
if the frame is marked as hidden with the is hidden-from-backtrace
trait.
my = Backtrace.new;my = [0];say .is-hidden;
method is-routine(Backtrace::Frame: --> Bool)
Return True
if the frame points into a routine (and not into a mere Block).
my = Backtrace.new;my = [0];say .is-routine;
method is-setting(Backtrace::Frame: --> Bool)
Returns True
if the frame is part of a setting.
my = Backtrace.new;my = [0];say .is-setting; # OUTPUT: «True»