All notable changes to this project will be documented in this file.
- Add
YYJSON_WRITE_PRETTY_TWO_SPACES
option to allow 2 spaces instead of 4 spaces when writing pretty JSON: #99 - Add yyjson_get_num() function to convert and return any number value as
double
: #108.
- Change allocator's realloc function signature, add
old_size
parameter (just ignore the parameter if your allocator doesn't need it): #100 - Change yyjson_read_number() function, add
alc
parameter.
- Fix inaccurate error code for truncated JSON: #103
- Add functions to modify the content of a JSON value, for example
yyjson_set_int(yyjson_val *val, int num)
. - Add functions to copy from mutable doc to immutable doc.
- Add functions to support renaming an object's key.
- Add the
yyjson_read_number()
function to parse numeric strings. - Add a placeholder allocator if
yyjson_alc_pool_init()
fails.
- Fix quite NaN on MIPS and HPPA arch.
- Fixed compile error before
GCC 4.5
which doesn't support empty optional extended asm label. - When built-in floating point conversion is disabled, sprintf() output for floating point numbers is missing a decimal point, for example 123 should be 123.0.
- Fix run-time error when compiling as cpp and 32-bit (g++-5 -m32 -fPIC) #85
- Fix incurrect output number format, remove unnecessary digits (e.g. 2.0e34 -> 2e34).
- Add LibFuzzer support.
- Add Doxygen support.
- Add functions to support serializing a single JSON value.
- Add
yyjson_mut_doc_mut_copy()
,yyjson_mut_val_mut_copy()
,yyjson_mut_merge_patch()
function for mutable input. - Add
yyjson_equals()
andyyjson_mut_equals()
function to compare two values. - Add
yyjson_mut_obj_remove_key()
andyyjson_mut_obj_remove_keyn()
to make it easier to remove a key. - Add
YYJSON_READ_NUMBER_AS_RAW
option andRAW
type support. - Add
YYJSON_READ_ALLOW_INVALID_UNICODE
andYYJSON_WRITE_ALLOW_INVALID_UNICODE
options to allow invalid unicode.
- Change
yyjson_mut_obj_remove()
return type frombool
toyyjson_mut_val *
. - Rewrite string serialization function, validate unicode encoding by default.
- Rewrite the JSON Pointer implementation, remove internal malloc() calls.
- Make the code work correctly with setlocale() function and fast-math flag: #54
- Fix negative infinity literals read error: #64
- Fix non null-terminated string write error.
- Fix incorrect behavior of
YYJSON_DISABLE_NON_STANDARD
flag: #80
- Add
YYJSON_WRITE_INF_AND_NAN_AS_NULL
flag for JSON writer. - Add
yyjson_merge_patch()
function for JSON Merge-Path API (RFC 7386). - Add
yyjson_mut_obj_replace()
andyyjson_mut_obj_insert()
function for object modification. - Add
yyjson_obj_iter_get()
andyyjson_mut_obj_iter_get()
function for faster object search. - Add
yyjson_version()
function.
- Replace
YYJSON_DISABLE_COMMENT_READER
andYYJSON_DISABLE_INF_AND_NAN_READER
withYYJSON_DISABLE_NON_STANDARD
compiler flag. - Replace
YYJSON_DISABLE_FP_READER
andYYJSON_DISABLE_FP_WRITER
withYYJSON_DISABLE_FAST_FP_CONV
compiler flag.
- Fix compiler warning with
-Wconversion
- Fix compiler error for GCC 4.4 (#53) and MSVC 6.0 (#55)
- Add
JSON Pointer
support. - Add CMake install target.
- Improve performance for some arch which doesn't support unaligned memory access.
- Fix some compiler warning for GCC and Clang.
- Fix MSVC build error on UWP (uninitialized local variable).
- Fix stream file reading error on some platform.
- Add swift package manager support.
- Improve JSON reader performance for gcc.
- Improve double number reader performance with a fast path.
- Rewrite double number writer with Schubfach algorithm: #4.
- Strict UTF-8 validation for JSON reader.
- Remove
YYJSON_READ_FASTFP
compiler flag.
- Fix a compile error for old version gcc on linux: #7.
- Initial release.
- Add the basic JSON reader and writer (RFC 8259).
- Add CMake support.
- Add GitHub CI workflow.
- Add test code and test data.
- Add
sanitizer
andvalgrind
memory checker. - Add
API
andDataStructure
documentation.