[Top][All Lists]

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

Re: guile-json 0.2.0 released

From: Panicz Maciej Godek
Subject: Re: guile-json 0.2.0 released
Date: Fri, 5 Apr 2013 09:35:03 +0200

2013/4/5 Aleix Conchillo Flaqué <address@hidden>
Thank you both for the comments.

I must admit that I got kind of lost and I ended up not knowing if you
had any specific suggestions for guile-json. It is my very first guile
(scheme) package and I am pretty new to scheme.

>From what I understood, the main concerns were:

1. Hash tables might not be a proper way to represent JSON objects.

2. Syntax for accessing JSON objects.

For 1, as Taylan mentioned, clearly says that JSON objects
are unordered. So I thought a hash table was the right data structure
to use. I initially thought about using association lists, but that's
ordered and performance might be worst for large objects.

Yes, so as it turns out, it was my ignorance that caused me to raise this topic :)
Hash tables are fine, but I think that guile's support for them isn't convinient, because their print representation isn't very informative (which occured to me when I was trying to test how exactly guile-json works)
May be it would be better to have a json-object type and procedures to
access it (json-object-ref ...) and internally it could be a hash
table, or an alist. Then, maybe, the user could specify if he wants to
get ordered json-objects or not, and internally use hash tables or

I think that, if the specification says that it's unordered, there's no actual need to complicate things overly :)
For 2, yes, a better syntax would be ideal. I don't know about
SRFI-105, but I'll take a look into it.

SRFI-105 offers only infix/m-exp notation within curly braces and a more decent way to index arrays (using postfix brackets, as in most popular programming languages)

Sorry if I caused unnecessary confusion ;o

Best regards

reply via email to

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