Skip to content

dbstack

miscellaneous · scripts/miscellaneous/dbstack.m

: s = dbstack ()
: s = dbstack (n)
: s = dbstack ("-completenames")
: [s, i] = dbstack (…)

Return or display the function call stack.

Prefers the interpreter builtin (skipping this wrapper frame). Ensures MATLAB fields file, name, and line are present. Extra Nexus fields such as column are preserved when the builtin supplies them.