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

Unified Diff: src/harmony-tostring.js

Issue 667263004: Remove [[PROTOTYPE]] from ObjectToStringHarmony (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 2 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/harmony-tostring.js
diff --git a/src/harmony-tostring.js b/src/harmony-tostring.js
index 282b3a0ffbd23c3a2aa3feaf72144aa07b4143b0..41a84dff6e0079a6ef953f522bf4820c7818742b 100644
--- a/src/harmony-tostring.js
+++ b/src/harmony-tostring.js
@@ -56,11 +56,19 @@ HarmonyToStringExtendSymbolPrototype();
function HarmonyToStringExtendObjectPrototype() {
%CheckIsBootstrapping();
+ // Can't use InstallFunctions() because will fail in Debug mode.
+ // Emulate InstallFunctions() here.
+ %FunctionSetName(ObjectToStringHarmony, "toString");
+ %FunctionRemovePrototype(ObjectToStringHarmony);
+ %SetNativeFlag(ObjectToStringHarmony);
+
// Set up the non-enumerable functions on the Array prototype object.
var desc = ToPropertyDescriptor({
value: ObjectToStringHarmony
});
DefineOwnProperty($Object.prototype, "toString", desc, false);
+
+ %ToFastProperties($Object.prototype);
}
HarmonyToStringExtendObjectPrototype();
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698