In Backtrace::Frame§

See primary documentation in context for method is-hidden

method is-hidden(Backtrace::Frame:D: --> Bool:D)

Returns True if the frame is marked as hidden with the is hidden-from-backtrace trait.

my $bt = Backtrace.new;
my $btf = $bt[0];
say $btf.is-hidden;