pub unsafe extern "C" fn yyjson_read_fp(
fp: *mut FILE,
flg: yyjson_read_flag,
alc: *const yyjson_alc,
err: *mut yyjson_read_err,
) -> *mut yyjson_docExpand description
Read JSON from a file pointer.
@param fp The file pointer.
The data will be read from the current position of the FILE to the end.
If this fp is NULL or invalid, the function will fail and return NULL.
@param flg The JSON read options.
Multiple options can be combined with | operator. 0 means no options.
@param alc The memory allocator used by JSON reader.
Pass NULL to use the libc’s default allocator.
@param err A pointer to receive error information.
Pass NULL if you don’t need error information.
@return A new JSON document, or NULL if an error occurs.
When it’s no longer needed, it should be freed with yyjson_doc_free().
@warning On 32-bit operating system, files larger than 2GB may fail to read.