joyent/node — pull request #8312 by errendir (2014-09-03 18:19:56+00:00)
Title: fs.stat third parameter controlling error creation

In some environment (especially when coffescript is involved) module.js
will spend a lot of time looking up nonexisting files. This is caused by the
lengthy error creation. Those errors are then immediately caught.

This change makes the lookup much faster, by avoiding the unnecessary error
creation.

module::statPath now uses the new second parameter of fs.statSync function of the
fs.js. There is a similar change for the fs.stat, adding the third parameter.

Apply suggestions from libuv pull request

Thanks saghul: https://github.com/joyent/libuv/pull/1428

Fix the datastructures for async

Documentation update

Add tests and simplify Stat function

Apply the code review comments