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

Unified Diff: src/js/promise.js

Issue 2630593004: [promises] Remove runtime call from fastpath in PromiseReject (Closed)
Patch Set: remove helper Created 3 years, 11 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/js/prologue.js ('k') | src/runtime/runtime.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/js/promise.js
diff --git a/src/js/promise.js b/src/js/promise.js
index 13d548cda85fd9a4425df625e4b70a583fca7929..95ab793591c04e3f2c3932a89b85f2742842cadf 100644
--- a/src/js/promise.js
+++ b/src/js/promise.js
@@ -29,13 +29,6 @@ SET_PRIVATE(PromiseIdRejectHandler, promiseForwardingHandlerSymbol, true);
// -------------------------------------------------------------------
// Define exported functions.
-// For bootstrapper.
-
-// Export to bindings
-function DoRejectPromise(promise, reason) {
- %PromiseReject(promise, reason, true);
-}
-
// Combinators.
// ES#sec-promise.all
@@ -136,10 +129,6 @@ function PromiseRace(iterable) {
return deferred.promise;
}
-function MarkPromiseAsHandled(promise) {
- %PromiseMarkAsHandled(promise);
-}
-
// -------------------------------------------------------------------
// Install exported functions.
@@ -149,17 +138,8 @@ utils.InstallFunctions(GlobalPromise, DONT_ENUM, [
]);
%InstallToContext([
- "promise_reject", DoRejectPromise,
"promise_id_resolve_handler", PromiseIdResolveHandler,
"promise_id_reject_handler", PromiseIdRejectHandler
]);
-// This allows extras to create promises quickly without building extra
-// resolve/reject closures, and allows them to later resolve and reject any
-// promise without having to hold on to those closures forever.
-utils.InstallFunctions(extrasUtils, 0, [
- "rejectPromise", DoRejectPromise,
- "markPromiseAsHandled", MarkPromiseAsHandled
-]);
-
})
« no previous file with comments | « src/js/prologue.js ('k') | src/runtime/runtime.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698