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

Unified Diff: src/proxy.js

Issue 1154743003: Revert of Hook up more import/exports in natives. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 7 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/promise.js ('k') | src/regexp.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/proxy.js
diff --git a/src/proxy.js b/src/proxy.js
index 782035b6f0b407edc0ac66b5e5491fc4bce86c8f..93ad8ddb0dd2ca51df2b95eb69a67431b4928f1e 100644
--- a/src/proxy.js
+++ b/src/proxy.js
@@ -2,8 +2,11 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
+var $proxyDelegateCallAndConstruct;
var $proxyDerivedGetTrap;
var $proxyDerivedHasTrap;
+var $proxyDerivedHasOwnTrap;
+var $proxyDerivedKeysTrap;
var $proxyDerivedSetTrap;
var $proxyEnumerate;
@@ -13,19 +16,10 @@
%CheckIsBootstrapping();
-// ----------------------------------------------------------------------------
-// Imports
-
var GlobalFunction = global.Function;
var GlobalObject = global.Object;
-var ToNameArray;
-
-utils.Import(function(from) {
- ToNameArray = from.ToNameArray;
-});
-
-//----------------------------------------------------------------------------
+// -------------------------------------------------------------------
function ProxyCreate(handler, proto) {
if (!IS_SPEC_OBJECT(handler))
@@ -181,7 +175,7 @@
if (IS_UNDEFINED(handler.enumerate)) {
return %Apply(DerivedEnumerateTrap, handler, [], 0, 0)
} else {
- return ToNameArray(handler.enumerate(), "enumerate", false)
+ return $toNameArray(handler.enumerate(), "enumerate", false)
}
}
@@ -191,23 +185,17 @@
%AddNamedProperty(global, "Proxy", Proxy, DONT_ENUM);
//Set up non-enumerable properties of the Proxy object.
-utils.InstallFunctions(Proxy, DONT_ENUM, [
+$installFunctions(Proxy, DONT_ENUM, [
"create", ProxyCreate,
"createFunction", ProxyCreateFunction
])
-// -------------------------------------------------------------------
-// Exports
-
+$proxyDelegateCallAndConstruct = DelegateCallAndConstruct;
$proxyDerivedGetTrap = DerivedGetTrap;
$proxyDerivedHasTrap = DerivedHasTrap;
+$proxyDerivedHasOwnTrap = DerivedHasOwnTrap;
+$proxyDerivedKeysTrap = DerivedKeysTrap;
$proxyDerivedSetTrap = DerivedSetTrap;
$proxyEnumerate = ProxyEnumerate;
-utils.Export(function(to) {
- to.ProxyDelegateCallAndConstruct = DelegateCallAndConstruct;
- to.ProxyDerivedHasOwnTrap = DerivedHasOwnTrap;
- to.ProxyDerivedKeysTrap = DerivedKeysTrap;
-});
-
})
« no previous file with comments | « src/promise.js ('k') | src/regexp.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698