Skip to content

Error: call stack overflow produces too much stack trace information #205

@ahaoboy

Description

@ahaoboy

When executing a script to detect the maximum recursion depth, it displays excessive call stack information.

function f(n) {
  console.log(n)
  return f(n + 1)
}

f(0)

mujs

1019
1020
Error: call stack overflow
        at f (./a.js:2)
        at f (./a.js:3)
        at f (./a.js:3)
... The other thousand lines
597
598
Possibly unhandled promise rejection: RangeError: Maximum call stack size exceeded
    at f (./a.js:2:15)
    at f (./a.js:3:16)
    at f (./a.js:3:16)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions