-
Notifications
You must be signed in to change notification settings - Fork 11
Support for Error Cause #41
Copy link
Copy link
Open
Labels
Description
Pony Cause (Error Cause ponyfill) has stackWithCauses function that generate a stack trace string with cause errors. Make sense to add function like System.getStackStringWithCauses.
Error: something really bad happened here: something bad happened
at Object.<anonymous> (/examples/fullStack.js:5:12)
at Module._compile (module.js:409:26)
at Object.Module._extensions..js (module.js:416:10)
at Module.load (module.js:343:32)
at Function.Module._load (module.js:300:12)
at Function.Module.runMain (module.js:441:10)
at startup (node.js:139:18)
at node.js:968:3
caused by: Error: something bad happened
at Object.<anonymous> (/examples/fullStack.js:3:12)
at Module._compile (module.js:409:26)
at Object.Module._extensions..js (module.js:416:10)
at Module.load (module.js:343:32)
at Function.Module._load (module.js:300:12)
at Function.Module.runMain (module.js:441:10)
at startup (node.js:139:18)
at node.js:968:3
This feature has nothing to do with compatibility, which is the motivation for this proposal, so it may be better to proceed as a separate proposal. However, I thought it was worth having this issue here for discussion.
related: #22, tc39/proposal-error-cause#16, tc39/proposal-error-cause#41
Reactions are currently unavailable