However they ended up having to modify json2.js to succeed rather than
the native Firefox JSON methods. Obviously we'd rather not have two
kinds of JSON code in Firebug.
Apparently the problem is that the native functions fail with too much
recursion on cycles, sometimes.
The closest bug I found in bugzilla is
https://bugzilla.mozilla.org/show_bug.cgi?id=512447
JSON.stringify does not correct handle replacer functions that produce
infinitely recursive objects
Is anyone familiar with the status of native JSON support? If it is "we
got most of it and now we are working on the rest" we'll just hold off
on our feature.
Thanks,
jjb
We're committed to fixing known JSON bugs, not sure if some of them
are already fixed on trunk or tracemonkey. sayre will know more,
copying him here and moving to the JS engine group. We should get
those bugs fixed and their fixes backported, though, rather than
carrying another, lower-perf impl in Firebug.
If that bug isn't exactly what you're seeing, please provide much more
detail about the input you're providing to the stringify call -- the
ES5 spec covers some aspects of cycle behaviour, IIRC, but I thought
json2.js was also conforming, so there might be something else that's
up.
Mike
From this email, I can't tell what the desired behavior is.
Can you give a simple test case and the expected results?