Commit message (Collapse) | Author | Files | Lines | ||
---|---|---|---|---|---|
2012-03-04 | Rename "cjson-misc" module to "cjson.util" | Mark Pulford | 5 | -24/+24 | |
2012-03-04 | Move cjson-misc and scripts to "lua" directory | Mark Pulford | 3 | -0/+0 | |
2012-03-04 | Use DISABLE_INVALID_NUMBERS on WIN32 CMake builds | Mark Pulford | 1 | -7/+7 | |
2012-03-04 | Fix typo in manual | Mark Pulford | 1 | -2/+2 | |
2012-03-04 | Update cjson-misc.lua file description | Mark Pulford | 1 | -1/+1 | |
2012-03-04 | Improve performance by tracking decode ptr | Mark Pulford | 1 | -46/+49 | |
Track pointer to the current location in the JSON string, instead of an index to the string array. Improves decode performance 1-10%. json_next_token(): - Clean up white space handling and leave "ch" containing the current non-whitespace character. | |||||
2012-03-04 | Update bench.lua to support different JSON modules | Mark Pulford | 3 | -41/+62 | |
- Select via JSON_MODULE environment variable (default "cjson") - Custom runtime configuration can be stored in bench-MODNAME.lua - Add run_script() to cjson-misc and update lua2cjson.lua | |||||
2012-03-04 | Add support to USE_INTERNAL_DTOA to CMake build | Mark Pulford | 1 | -7/+41 | |
- Provide build options for USE_INTERNAL_DTOA and MULTIPLE_THREADS - Link module with Lua library under Windows | |||||
2012-03-04 | Limit significant digits in numbers.json to 14 | Mark Pulford | 1 | -6/+6 | |
The dtoa.c strtod() function slows down significantly when the number of digits exceeds the accuracy of a "double". JSON containing excessive digits is an unrepresentative test, limit to 14 digits. | |||||
2012-03-04 | Add error checking to dtoa locking primitives | Mark Pulford | 1 | -4/+12 | |
2012-03-04 | Document dtoa build options | Mark Pulford | 1 | -0/+16 | |
2012-03-04 | Use internal dtoa/strtod for double conversion | Mark Pulford | 6 | -16/+123 | |
The internal Lua CJSON dtoa/strtod routines have locale support disabled. This avoids problems under locales with comma decimal separators. Build changes: - CMake: Check for big endian architectures - Makefile: Provide option to build with dtoa.c Modifications to dtoa.c: - Include locale dtoa_config.h configuration - Rename Infinity/NaN to inf/nan to match common C libraries - Rename strtod() -> internal_strtod() to prevent conflict with libc function Modifications to g_fmt.c: - Return output string length (instead of original buffer pointer) - Provide precision as an argument to g_fmt() - Silence compilations warnings from vendor source - while(a = b) - Unused label "done:" - Only swap to scientific notation when once the number of decimal digits required exceeds the precision available. This matches standard printf format %g. - Display a "0" in front of numbers < 1. | |||||
2012-01-03 | Add support for Lua 5.2 environments to lua2json | Mark Pulford | 1 | -9/+23 | |
2012-01-03 | Rename encode/decode scripts to lua2json/json2lua | Mark Pulford | 2 | -6/+6 | |
2012-01-03 | Convert common.lua into cjson-misc module | Mark Pulford | 5 | -35/+43 | |
2012-01-02 | Tidy Makefile sections and comments | Mark Pulford | 1 | -17/+16 | |
2012-01-02 | Fix Windows TARGET modifications | Mark Pulford | 1 | -3/+3 | |
2012-01-02 | Fix typos (lists, hexadecimal) | Mark Pulford | 2 | -9/+9 | |
2012-01-02 | Update all package descriptions for consistency | Mark Pulford | 3 | -9/+19 | |
2012-01-01 | Add build option to disable invalid numbers | Mark Pulford | 4 | -16/+39 | |
Windows MinGW doesn't convert Infinity/NaN/hexadecimal numbers. Add DISABLE_INVALID_NUMBERS build option option to disable invalid numbers. | |||||
2012-01-01 | Sanitise locale code, comments and documentation | Mark Pulford | 4 | -41/+71 | |
2012-01-01 | Add Windows MinGW target to Makefile | Mark Pulford | 1 | -4/+12 | |
2011-12-31 | Add NDEBUG to performance CFLAGS | Mark Pulford | 1 | -1/+1 | |
2011-12-31 | Remove redundant comment from test.lua | Mark Pulford | 1 | -7/+0 | |
2011-12-31 | Update NEWS for 1.0.5 | Mark Pulford | 1 | -1/+5 | |
2011-12-31 | Minor code cleanup | Mark Pulford | 1 | -10/+12 | |
- Sanitised arg ordering to encode functions - Commented json->tmp to explain why decode string processing uses strbuf_*_unsafe() functions. | |||||
2011-12-31 | Remove "update_locale" Lua function | Mark Pulford | 2 | -10/+2 | |
Only update the locale when the module is initialised. cjson.new() can be used if the locale changes part way through program execution. | |||||
2011-12-31 | Add option for private buffer | Mark Pulford | 1 | -26/+44 | |
When encode_keep_buffer is false, a private buffer will be used. This will allow multiple encoders to run within a single Lua state. | |||||
2011-12-31 | Fix minor warning from Clang analyzer | Mark Pulford | 1 | -1/+1 | |
2011-12-31 | Remove shared current_depth var from cfg struct | Mark Pulford | 1 | -25/+17 | |
2011-12-30 | Remove strbuf:die() from global symbol table | Mark Pulford | 1 | -1/+1 | |
2011-12-30 | Add support for Lua 5.2 and cjson.new | Mark Pulford | 8 | -47/+122 | |
Update all Lua scripts to use new module init style everywhere: local json = require "cjson" Lua CJSON does not register a global table under Lua 5.2. The global table can be disabled under Lua 5.1 with DISABLE_CJSON_GLOBAL. Other changes: - Store CJSON configuration as an upvalue for each function. - Add "cjson.new" function to create another module table with a separate configuration. - Add _NAME and _VERSION variables. | |||||
2011-12-30 | Add fpconv to work around comma decimal points | Mark Pulford | 8 | -20/+206 | |
Create a separate buffer and translate comma <> dot before calling strtod(), and after calling sprintf() as required. - Add "update_locale" Lua API call and init locale on module load. - Move sprintf format string to fpconv | |||||
2011-12-29 | Remove POSIX locale workaround | Mark Pulford | 6 | -124/+4 | |
2011-12-30 | Display success when all tests pass | Mark Pulford | 1 | -3/+4 | |
2011-12-29 | Added Netlib dtoa.c/g_fmt.c routines (20110428) | Mark Pulford | 2 | -0/+4460 | |
See "www.netlib.org/fp/changes" for details. | |||||
2011-12-26 | Display failed test count (test.lua) | Mark Pulford | 1 | -1/+1 | |
2011-12-26 | Generate git tag based version number for packages | Mark Pulford | 1 | -20/+10 | |
2011-12-24 | Fix typo in lua_cjson.c | Mark Pulford | 1 | -1/+1 | |
2011-12-20 | Clarify optional args and return values | Mark Pulford | 1 | -0/+15 | |