<preclass='rust fn'>pub fn trace<F: <aclass="trait"href="https://doc.rust-lang.org/nightly/core/ops/function/trait.FnMut.html"title="trait core::ops::function::FnMut">FnMut</a>(&<aclass="struct"href="../backtrace/struct.Frame.html"title="struct backtrace::Frame">Frame</a>) -><aclass="primitive"href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a>>(cb: F)</pre><divclass='docblock'><p>Inspects the current call-stack, passing all active frames into the closure
provided to calculate a stack trace.</p>
<p>This function is the workhorse of this library in calculating the stack
traces for a program. The given closure <code>cb</code> is yielded instances of a
<code>Frame</code> which represent information about that call frame on the stack. The
closure is yielded frames in a top-down fashion (most recently called
functions first).</p>
<p>The closure's return value is an indication of whether the backtrace should
continue. A return value of <code>false</code> will terminate the backtrace and return
immediately.</p>
<p>Once a <code>Frame</code> is acquired you will likely want to call <code>backtrace::resolve</code>
to convert the <code>ip</code> (instruction pointer) or symbol address to a <code>Symbol</code>
through which the name and/or filename/line number can be learned.</p>
<p>Note that this is a relatively low-level function and if you'd like to, for
example, capture a backtrace to be inspected later, then the <code>Backtrace</code>