Yaoyuan Guo
Yaoyuan Guo
This looks good. I have seen this design in `cJSON` before, maybe we can name the type as `YYJSON_TYPE_RAW` just like `cJSON`, and we can add a `YYJSON_READ_NUMBER_AS_RAW` flag for...
> I just wanted to create a similar request. IMO, this should have been there from the start. A simple case is reading regular floats: often basic numbers, like `123.4`...
Added: https://github.com/ibireme/yyjson/commit/804a8b2771e6bfb273a797f6c2413568a92e7874 Now you can use the `YYJSON_READ_NUMBER_AS_RAW` flag to parse all numbers as `YYJSON_TYPE_RAW` values: ``` bool yyjson_is_raw(yyjson_val *val); const char *yyjson_get_raw(yyjson_val *val); size_t yyjson_get_len(yyjson_val *val) ``` And when...
> with floats even if they can be parsed to native, they won't be identical if serialized. That's why it would be useful to be able to access raw string...
I added some functions as you suggested: https://github.com/ibireme/yyjson/commit/ee9e6d5d3bde4a26b78e9cfd596dd28d231266fa, and here is an example: ```c // build JSON on stack yyjson_mut_val root, code_key, code, msg_key, msg, arr_key, arr, n1, n2; yyjson_mut_set_obj(&root);...
I do have plans to add a streaming or SAX API, maybe in version 0.5 or 0.6.
@zhoufei1 Please open a new issue.
Since the container here is implemented with a circular linked list, I thought it would be enough to return a previous node (previous value in array or previous key in...
Thanks. I will add more documentation and demos later.
一般讲 LRU,是只把最近访问的对象挪到前面,不用的对象就会渐渐挪到队尾等待淘汰,这里不需要统计访问频率。 统计频率的算法可以看看 LRU-K。