Skip to content

Commit

Permalink
errors: prevent stack recalculation
Browse files Browse the repository at this point in the history
Newer v8 versions exclude the constructor from the stack trace
so the recalculation of the trace can be avoided.

PR-URL: #13743
Reviewed-By: Luigi Pinca <[email protected]>
Reviewed-By: Timothy Gu <[email protected]>
Reviewed-By: James M Snell <[email protected]>
Reviewed-By: Michael Dawson <[email protected]>
Reviewed-By: Refael Ackermann <[email protected]>
  • Loading branch information
BridgeAR authored and addaleax committed Jun 29, 2017
1 parent bf69891 commit 52ebab0
Showing 1 changed file with 0 additions and 1 deletion.
1 change: 0 additions & 1 deletion lib/internal/errors.js
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@ function makeNodeError(Base) {
constructor(key, ...args) {
super(message(key, args));
this[kCode] = key;
Error.captureStackTrace(this, NodeError);
}

get name() {
Expand Down

0 comments on commit 52ebab0

Please sign in to comment.