util: add decorateErrorStack()
authorcjihrig <cjihrig@gmail.com>
Wed, 25 Nov 2015 00:52:35 +0000 (19:52 -0500)
committerMyles Borins <mborins@us.ibm.com>
Tue, 19 Jan 2016 19:52:28 +0000 (11:52 -0800)
commit422a865d467e19c7b1b24ab94f0ebce2fce2dddc
tree2ce03d114bce8650920b6a8f908ca2024c6ab295
parent1bf84b9d4165163ad7ea93ee08cc7e80977c2c97
util: add decorateErrorStack()

This commit adds the decorateErrorStack() method. This function
uses the internal util's getHiddenValue() method to extract
arrow messages from error objects and attach them to the
error's stack trace.

PR-URL: https://github.com/nodejs/node/pull/4013
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
lib/util.js
test/parallel/test-util-decorate-error-stack.js [new file with mode: 0644]