name: duk_inspect_callstack_entry proto: | void duk_inspect_callstack_entry(duk_context *ctx, duk_int_t level); stack: | [ ... ] -> [ ... info! ] summary: |
Inspect callstack entry at level
and push an object
containing Duktape specific internal information about the entry.
The level argument must be negative and mimics the value stack
index convention: -1 is the most recent (innermost) call, -2 is its
caller, and so on. If the level argument is invalid (e.g. outside of
current callstack) undefined
is pushed instead.
The following table summarizes current properties.
Property | Description |
---|---|
function | Function being executed. Note that this is a potential sandboxing concern if exposed to untrusted code. |
pc | Program counter for Ecmascript functions. Zero if executing a native function. |
lineNumber | Line number for Ecmascript functions. Zero if executing a native function or if pc-to-line translation data is not available. |