Skip to content

Error Trace Rt

Spice
import "std/runtime/error_trace_rt";

Functions

sErrTraceReset

Spice
public p sErrTraceReset(string signature, string file, unsigned int line, unsigned int column)

Starts a fresh trace with the given location as its origin (frame 0).

Parameters

Name Type Description
signature string
file string
line unsigned int
column unsigned int

sErrTracePush

Spice
public p sErrTracePush(string signature, string file, unsigned int line, unsigned int column)

Appends a propagation hop to the current trace.

Parameters

Name Type Description
signature string
file string
line unsigned int
column unsigned int

sErrTraceDump

Spice
public p sErrTraceDump()

Prints every recorded frame of the current thread's trace. A no-op if there is no active trace, which also covers the case where error return tracing was never enabled anywhere along the propagation chain in the first place - callers don't need to check that separately (see Error.dumpTrace() and panic()'s own wiring, both of which call this unconditionally).