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

Unified Diff: src/promise.js

Issue 1306993003: Call JS functions via native context instead of js builtins object. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: rebase Created 5 years, 4 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/prologue.js ('k') | src/proxy.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/promise.js
diff --git a/src/promise.js b/src/promise.js
index 31b6cc12468dcefefb51c89048f0a497e8f6283d..db1f36095d11c95fd5921e953a214d39c5f9aa30 100644
--- a/src/promise.js
+++ b/src/promise.js
@@ -379,15 +379,14 @@ utils.InstallFunctions(GlobalPromise.prototype, DONT_ENUM, [
"catch", PromiseCatch
]);
-utils.ExportToRuntime(function(to) {
- to["promise_catch"] = PromiseCatch;
- to["promise_chain"] = PromiseChain;
- to["promise_create"] = PromiseCreate;
- to["promise_has_user_defined_reject_handler"] =
- PromiseHasUserDefinedRejectHandler;
- to["promise_reject"] = PromiseReject;
- to["promise_resolve"] = PromiseResolve;
- to["promise_then"] = PromiseThen;
-});
+%InstallToContext([
+ "promise_catch", PromiseCatch,
+ "promise_chain", PromiseChain,
+ "promise_create", PromiseCreate,
+ "promise_has_user_defined_reject_handler", PromiseHasUserDefinedRejectHandler,
+ "promise_reject", PromiseReject,
+ "promise_resolve", PromiseResolve,
+ "promise_then", PromiseThen,
+]);
})
« no previous file with comments | « src/prologue.js ('k') | src/proxy.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698