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

Unified Diff: src/js/json.js

Issue 1994183002: [json] handle proxies in BasicJsonSerializer. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: address comments Created 4 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/builtins.cc ('k') | src/json-stringifier.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/js/json.js
diff --git a/src/js/json.js b/src/js/json.js
index 09fe688ebb1dca2755bb11e83329a5b68c749517..f5c0ae7a3cb7219d7d106bbf27205939871fce0c 100644
--- a/src/js/json.js
+++ b/src/js/json.js
@@ -201,9 +201,7 @@ function JSONSerialize(key, holder, replacer, stack, indent, gap) {
function JSONStringify(value, replacer, space) {
- if (arguments.length === 1 && !IS_PROXY(value)) {
- return %BasicJSONStringify(value, "");
- }
+ if (arguments.length === 1) return %BasicJSONStringify(value, "");
if (!IS_CALLABLE(replacer) && %is_arraylike(replacer)) {
var property_list = new InternalArray();
var seen_properties = new GlobalSet();
@@ -248,7 +246,7 @@ function JSONStringify(value, replacer, space) {
} else {
gap = "";
}
- if (!IS_CALLABLE(replacer) && !property_list && !IS_PROXY(value)) {
+ if (!IS_CALLABLE(replacer) && !property_list) {
return %BasicJSONStringify(value, gap);
}
return JSONSerialize('', {'': value}, replacer, new Stack(), "", gap);
« no previous file with comments | « src/builtins.cc ('k') | src/json-stringifier.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698