[cl-json-devel] cl-json 0.4

Boris Smilga boris.smilga at gmail.com
Mon Apr 6 10:19:15 UTC 2009


Good day to everyone.

The bundle attached herewith contains patches to upgrade CL-JSON to  
the new version 0.4.0 which incorporates changes we have been  
discussing of late.  The changes are rather wide-scale (the sheer  
size of the patches is 415k), almost every aspect of the  
implementation differs from what we had in version 0.3.1 and  
earlier.  The most important points are:

1.  The decoder now has the customization mechanism from decoder- 
vars.lisp, with imperative handlers and aggregate-scope variables.

2.  The encoder provides a streaming API (borrowed from YASON).  The  
standard encode methods are re-implemented using that API.

3.  The CLOS decoder has undergone serious modifications to address  
the issue of degrading performance in some Lisp implementations.  It  
shall be possible to use anonymous “fluid” objects created by the  
decoder in a way which makes for a “poor man's JavaScript”.  The  
CLOS encoder does not emit prototype metadata anymore (unless  
specifically requested).

4.  I have written a new pair of matching functions to convert  
between camel case and Lisp names.

5.  There is an improved exception signalling mechanism.  Some things  
which previously were handled by callbacks now use conditions /  
restarts.

6.  JSON-BIND now uses the event-based decoder API with dynamic  
customization.  This has the advantage that the user may choose the  
semantics with which to decode interior values.  However, I had to  
forego the support for Lisp trees as arguments to JSON-BIND.

7.  Some exported names were changed:
         Condition JSON-PARSE-ERROR → JSON-SYNTAX-ERROR
         Macro WITH-LIST-DECODER-SEMANTICS → WITH-DECODER-SIMPLE- 
LIST-SEMANTICS
         Macro WITH-CLOS-DECODER-SEMANTICS → WITH-DECODER-SIMPLE- 
CLOS-SEMANTICS

I have made sure the tests pass in Clozure CL, SBCL, CMUCL, CLisp,  
and ECL.

There is a new User's Manual in doc/cl-json.html (I have also  
uploaded a copy to http://dpworks.net/smilga/cl-json.html).  And here  
I would like to humbly ask someone on this mailing list who is a  
native speaker of English to proof-read it.  Russian, my natural  
idiom, is quite unlike English in grammar, conventional style, and  
punctuation. Though I am more or less fluent in the latter, I never  
fully trust myself, especially with the choice of articles,  
“which” / “that”, and modal and causative constructions.   
Also, if you think some passages confused or inarticulate, by all  
means do not hesitate to point me to them. Thank you in advance.

Sincerely,
   - B. Smilga.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: version-0.4.dpatch.gz
Type: application/x-gzip
Size: 89158 bytes
Desc: not available
URL: <https://mailman.common-lisp.net/pipermail/cl-json-devel/attachments/20090406/2671fe02/attachment.bin>


More information about the cl-json-devel mailing list