chicken-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Chicken-users] Why does the JSON egg map JSON structs to Scheme vec


From: Christian Kellermann
Subject: Re: [Chicken-users] Why does the JSON egg map JSON structs to Scheme vectors instead of alists?
Date: Sun, 27 Nov 2011 14:43:00 +0100
User-agent: Mutt/1.5.21 (2010-09-15)

* Vok Vojwo <address@hidden> [111127 14:37]:
> 2011/11/27 Christian Kellermann <address@hidden>:
> >
> > My guess is that it makes it possible to write back to json, since
> > alists are already used for representing a different datatype.
> 
> But json-write does not accept alists as values. This
> 
> (json-write (vector (cons "x" (list (cons "a" 1) (cons "b" 2)))))
> 
> throws the following error:
> 
> Error: Invalid JSON object in json-write: ("a" . 1)

This is true. I mistook them for lists, which are already used.
Sorry for the noise.

-- 
Who can (make) the muddy water (clear)? Let it be still, and it will
gradually become clear. Who can secure the condition of rest? Let
movement go on, and the condition of rest will gradually arise.
 -- Lao Tse. 



reply via email to

[Prev in Thread] Current Thread [Next in Thread]