Commit graph

729 commits

Author SHA1 Message Date
alisdair sullivan
c743debc6d better tests for encoder, still needs more cases tho 2011-07-20 07:14:59 -07:00
alisdair sullivan
e7025efe50 is_json inputs now line up with format inputs 2011-07-17 20:55:54 -07:00
alisdair sullivan
fd3c6af50b new encoder now handles incomplete input 2011-07-17 20:55:54 -07:00
alisdair sullivan
2cdb755d08 new test for new encoder/formatter 2011-07-17 20:55:54 -07:00
alisdair sullivan
04dfde559e format/1,2 takes a list of terms as an argument now, in addition to binary json or a jsx_iterator 2011-07-17 20:55:54 -07:00
alisdair sullivan
9cee07212f add encoder/0 to jsx.erl 2011-07-17 20:55:54 -07:00
alisdair sullivan
0de13a2685 adds jsx_encoder.erl to mods list 2011-07-17 20:55:54 -07:00
alisdair sullivan
24492e2bdf type specs update 2011-07-17 20:55:54 -07:00
alisdair sullivan
cc10a736cd some basic tests for encoder 2011-07-17 20:55:54 -07:00
alisdair sullivan
746d8e469c renames jsx_opts to jsx_decoder_opts 2011-07-17 20:55:54 -07:00
alisdair sullivan
e80d337cc0 whitespace 2011-07-06 00:29:31 -07:00
alisdair sullivan
1422e69ef4 header file for is_json options 2011-07-05 21:42:39 -07:00
alisdair sullivan
f3aa254664 reworks is_json to be more lenient, optionally more strict 2011-07-05 21:42:08 -07:00
alisdair sullivan
51076f2054 Merge branch 'master' into stricter_parsing 2011-07-04 21:11:19 -07:00
alisdair sullivan
7079a6ead7 whitespace fixes for contributed patch 2011-07-04 21:07:50 -07:00
alisdair sullivan
922e3e525e removed now meaningless strict option from format and verify modules and associated types and specs 2011-07-04 21:04:10 -07:00
alisdair sullivan
9eec2459f4 Merge branch 'master' into stricter_parsing 2011-07-04 20:55:25 -07:00
alisdair sullivan
0052480652 is_json/2 and format/2 now both accept either a json text (binary) or a function that acts as a jsx iterator. specs updated to reflect 2011-07-04 19:25:09 -07:00
alisdair sullivan
e088c6fd26 fix whitespace in app.src 2011-07-04 16:34:14 -07:00
alisdair sullivan
686690ec99 removes options for unquoted keys and comments from eep0018 2011-07-04 16:33:14 -07:00
alisdair sullivan
51eb579f86 exports pow/2 from jsx_utils 2011-07-04 16:31:31 -07:00
alisdair sullivan
e20e6746a2 removes all traces of unquoted key and comment support 2011-07-03 17:42:44 -07:00
amtal
b9d10181ab switched to error/2 from error/1 in exported funcs
Passing a list of arguments in the second parameter, makes them
show up in the stack trace in place of the function arity number.

For referentially transparent functions (which foo_to_bar tend to
be) failures can then be reproduced from just the stack trace!

If using error/1, you must rely on some higher layer to add enough
info to reproduce the crash.
2011-06-23 14:41:51 -07:00
alisdair sullivan
e4cbe15fa7 fixes broken build from premature push, oops 2011-05-04 01:00:29 -07:00
alisdair sullivan
26e479fc84 removes include dir, headers now live in src 2011-05-03 15:22:44 -07:00
alisdair sullivan
77af00359f detect_encoding/2 uses decoder/1 instead of parser/1 2011-04-26 23:44:32 -07:00
alisdair sullivan
b2d923cbcb api change, parser/0,1 deprecated, replaced with decoder/0,1 2011-04-26 23:40:12 -07:00
alisdair sullivan
6cc28573b6 changes default for strict to false from true to better match other json encoders/decoders in the wild 2011-04-26 21:30:57 -07:00
alisdair sullivan
428858ed8c changes two rogue throw to error 2011-04-26 20:07:40 -07:00
alisdair sullivan
6481bae328 removes useless eventify function 2011-04-16 22:25:02 -07:00
alisdair sullivan
e22ec34000 moves encoding detection to jsx_utils 2011-04-16 22:18:59 -07:00
alisdair sullivan
216a71895a removes all edoc machinery 2011-03-22 19:02:28 -07:00
alisdair sullivan
32c9a1f00f integrates nicefloats into jsx 2011-03-22 18:53:02 -07:00
alisdair sullivan
0c3dbaab6c moved ebin/jsx.app to src/jsx.app.src 2011-03-22 18:46:14 -07:00
alisdair sullivan
a6e7490a2b options are now proplist style, so [comments] implies [{comments, true}] et cetera 2011-03-07 14:02:51 -08:00
alisdair sullivan
88da19783a embarasssssing 2011-02-28 15:11:36 -08:00
alisdair sullivan
91f503fc07 test for streaming eep0018 parser 2011-02-28 12:44:21 -08:00
alisdair sullivan
7e8e5a9a48 removed test for removed function 2011-02-28 12:29:28 -08:00
alisdair sullivan
c973abd1b2 json_to_term/2 now returns {incomplete, More} when input ends prematurely rather than an error tuple when called with the option {stream, true} 2011-02-28 12:28:06 -08:00
alisdair sullivan
8ed4b1a405 new test for read_file/1, /2 2011-02-21 19:47:20 -08:00
alisdair sullivan
dd46f4394b commented rethrown exceptions 2010-09-28 12:52:58 -07:00
alisdair sullivan
a4d48fd8d9 backed out ill conceived change to options 2010-09-27 14:52:16 -07:00
alisdair sullivan
5bcdca948a wrapped calls to jsx_eep0018 so that badarg exceptions are raised in the public api, rather than in internal modules 2010-09-27 14:27:39 -07:00
alisdair sullivan
a99644a926 modified error return value from {error, badjson} to {error, {badjson, Bin}} where Bin is the input from the point of the error 2010-09-27 14:07:36 -07:00
alisdair sullivan
1a20e911a9 was using three different methods to rewrite options to core parser options, switched to just one 2010-09-23 22:29:21 -07:00
alisdair sullivan
c1e58460e4 added probably superfluous test, for paranoia 2010-09-23 22:28:35 -07:00
alisdair sullivan
52511d24c1 formatter and verifier allow unquoted keys now too 2010-09-23 22:28:35 -07:00
alisdair sullivan
b73e506fe2 rewrote extraction of core parser options in various components in a consistent manner 2010-09-23 22:26:04 -07:00
alisdair sullivan
d67f830def incremented version number and added CHANGES 2010-09-22 23:12:54 -07:00
alisdair sullivan
fa4e2f533b moved contents of jsx_test to jsx module to adhere to law of conversation of module names 2010-09-21 08:05:08 -07:00