← All docs

debug_backtrace()

Generates a PHP backtrace for the active call stack.

debug_backtrace()

function debug_backtrace(int $options = 1, int $limit = 0): array

Generates a PHP backtrace for the active call stack.

Parameters:

  • $options (int), default 1, optional
  • $limit (int), default 0, optional

Returns: array

Availability

No examples yet. Check examples/ and showcases/ for usage patterns.

Internals

For how debug_backtrace is implemented in the compiler, see the internals page.