Closed Bug 512443 Opened 12 years ago Closed 12 years ago

JSON.stringify does not correct interact with replacer functions in objects

Categories

(Core :: JavaScript Engine, defect)

defect
Not set
normal

Tracking

()

RESOLVED DUPLICATE of bug 509184

People

(Reporter: oliver, Unassigned)

References

()

Details

User-Agent:       Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10_6; en-us) AppleWebKit/531.5 (KHTML, like Gecko) Version/4.0.3 Safari/531.7
Build Identifier: Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10_6; en-us) AppleWebKit/531.5 (KHTML, like Gecko) Version/4.0.3 Safari/531.7 Build Identifier: Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.6; en-US; rv:1.9.3a1pre) Gecko/20090824 Minefield/3.7a1pre

The linked test case shows that spidermonkey's JSON object is not correctly using the result of the replacer function when deserialising objects.

Reproducible: Always

Steps to Reproduce:
1. Run the testcase at http://trac.webkit.org/export/47743/trunk/LayoutTests/fast/js/JSON-stringify-replacer.html
2.  Note the first 3 failures
Actual Results:  
JSON object is ignoring the reviver function when deserialising objects.

Expected Results:  
All the tests should pass.
Ollie, I gave you canconfirm and editbugs bugzilla privs. No need to cc: me, I watch all js bugs.

/be
Status: UNCONFIRMED → NEW
Ever confirmed: true
Status: NEW → RESOLVED
Closed: 12 years ago
Resolution: --- → DUPLICATE
Duplicate of bug: 509184
You need to log in before you can comment on or make changes to this bug.