Lines Matching refs:Promise
52 module.exports = Promise;
54 function Promise(fn) { class
68 Promise._onHandle = null;
69 Promise._onReject = null;
70 Promise._noop = noop;
72 Promise.prototype.then = function(onFulfilled, onRejected) {
73 if (this.constructor !== Promise) {
76 var res = new Promise(noop);
83 var res = new Promise(noop);
92 if (Promise._onHandle) {
93 Promise._onHandle(self);
149 newValue instanceof Promise
168 if (Promise._onReject) {
169 Promise._onReject(self, newValue);