I have just completed a major rewrite of Tony Garnock-Jones's JSON egg. It's temporarily available at http://www.ccil.org/temp/json.egg . The JSON parser is untouched; however, the JSON generator has been completely redesigned. Here are the new features:
1) A Scheme object is completely validated for writability before any part of it is written. 2) An a-list (list of pairs) will be written as a JSON object (structure). Likewise, a vector containing writable objects rather than pairs will be written as a JSON list. (However, an empty Scheme list is written as a JSON list, whereas an empty Scheme vector is written as a JSON object.) 3) It is possible to add support for printing an arbitrary Scheme type as a JSON null, boolean, number, string, list, or object. You need to provide a few procedures for recognizing, writing, and walking the Scheme object, and pass them to json-add-atomic-type! or json-add-collection-type! 4) json-writable? and json-name? are exposed; they are true if the argument is writable as a JSON value or a JSON string respectively. Bugs and comments to me. Thanks and kudos to Tony for his parser. -- John Cowan http://ccil.org/~cowan [EMAIL PROTECTED] SAXParserFactory [is] a hideous, evil monstrosity of a class that should be hung, shot, beheaded, drawn and quartered, burned at the stake, buried in unconsecrated ground, dug up, cremated, and the ashes tossed in the Tiber while the complete cast of Wicked sings "Ding dong, the witch is dead." --Elliotte Rusty Harold on xml-dev _______________________________________________ Chicken-users mailing list Chicken-users@nongnu.org http://lists.nongnu.org/mailman/listinfo/chicken-users