debug.getcallstack returns non-hidden frames. Each entry contains the function and, for Luau frames, the current source line. OTH hook frames are followed into their linked original thread.
local function innerFunc() local stack = debug.getcallstack() for i, entry in ipairs(stack) do local info = debug.getinfo(entry.func) print(i, info.name or "anonymous", entry.currentline) endendlocal function outerFunc() innerFunc()endouterFunc()