librelist archives

« back to archive

YAJL limitations

YAJL limitations

Robert Henry
2011-07-14 @ 18:28
I'm kicking the tires on YAJL for use in an open source project.

I've noticed several (debatable) omissions that might help improve YAJL.

1:  There is no support for streaming yajl_tree_parse.  That can be
achieved by the usual conversion strategy of taking yajl_tree_parse apart at
the seams, and following some object-oriented-like coding involving
the usual C glop of opaque pointers, etc.

2: There is no support for optionally allowing commas as terminators
rather than as separators.  The JSON spec doesn't allow this, but this
is a common mistake people make when writing and maintaining json
config files, and you already support non standard JSON comments.

3: There is no support for converting textual representations of IEEE
"Infinity" or "NaN".  Alas, that also isn't part of the JSON spec for
what a number is.  (This is hurting me, actually, and the finite state machine
used in the lexer is a little painful.)