Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1584)

Side by Side Diff: src/js/promise.js

Issue 2278643002: Do not trigger ExceptionEvents for another forwarding case (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 4 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | test/mjsunit/es6/debug-promises/reject-caught-by-default-reject-handler.js » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 (function(global, utils, extrasUtils) { 5 (function(global, utils, extrasUtils) {
6 6
7 "use strict"; 7 "use strict";
8 8
9 %CheckIsBootstrapping(); 9 %CheckIsBootstrapping();
10 10
(...skipping 198 matching lines...) Expand 10 before | Expand all | Expand 10 after
209 deferred); 209 deferred);
210 210
211 SET_PRIVATE(promise, promiseFulfillReactionsSymbol, resolveCallbacks); 211 SET_PRIVATE(promise, promiseFulfillReactionsSymbol, resolveCallbacks);
212 SET_PRIVATE(promise, promiseRejectReactionsSymbol, rejectCallbacks); 212 SET_PRIVATE(promise, promiseRejectReactionsSymbol, rejectCallbacks);
213 } else { 213 } else {
214 maybeResolveCallbacks.push(onResolve, deferred); 214 maybeResolveCallbacks.push(onResolve, deferred);
215 GET_PRIVATE(promise, promiseRejectReactionsSymbol).push(onReject, deferred); 215 GET_PRIVATE(promise, promiseRejectReactionsSymbol).push(onReject, deferred);
216 } 216 }
217 } 217 }
218 218
219 function PromiseIdResolveHandler(x) { return x } 219 function PromiseIdResolveHandler(x) { return x; }
220 function PromiseIdRejectHandler(r) { throw r } 220 function PromiseIdRejectHandler(r) { %_ReThrow(r); }
221 221
222 function PromiseNopResolver() {} 222 function PromiseNopResolver() {}
223 223
224 // ------------------------------------------------------------------- 224 // -------------------------------------------------------------------
225 // Define exported functions. 225 // Define exported functions.
226 226
227 // For bootstrapper. 227 // For bootstrapper.
228 228
229 // ES#sec-ispromise IsPromise ( x ) 229 // ES#sec-ispromise IsPromise ( x )
230 function IsPromise(x) { 230 function IsPromise(x) {
(...skipping 412 matching lines...) Expand 10 before | Expand all | Expand 10 after
643 utils.Export(function(to) { 643 utils.Export(function(to) {
644 to.PromiseCastResolved = PromiseCastResolved; 644 to.PromiseCastResolved = PromiseCastResolved;
645 to.PromiseThen = PromiseThen; 645 to.PromiseThen = PromiseThen;
646 646
647 to.GlobalPromise = GlobalPromise; 647 to.GlobalPromise = GlobalPromise;
648 to.NewPromiseCapability = NewPromiseCapability; 648 to.NewPromiseCapability = NewPromiseCapability;
649 to.PerformPromiseThen = PerformPromiseThen; 649 to.PerformPromiseThen = PerformPromiseThen;
650 }); 650 });
651 651
652 }) 652 })
OLDNEW
« no previous file with comments | « no previous file | test/mjsunit/es6/debug-promises/reject-caught-by-default-reject-handler.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698