augmentation of prototypes with the for..in statement is evidence of
this. This defect in the language requires that for..in blocks
explicitly filter out unwanted stuff that is dredged up from the
prototype chain. See http://yuiblog.com/blog/2006/09/26/for-in-intrigue/
json.js provides the same API that will be built into ECMAScript
Fourth Edition. That means that if your program works with json.js,
then it will work even better when the language is revised.
Some people do not have the luxury of being forward looking. They have
to work with bad code that does not filter for..in, or they claim the
right to write bad code themselves. Those people should not be using
json.js. Fortunately, JSON encoding and decoding is so easy, there
isn't much effort required to make an implementation that works with
JSON is a standard data representation. The json.js implementation is
not the standard. It is a reference implementation. You are free to
use it in any way that you want, or to not use it.