f3b8f90b6d
ZSTD_create?Dict() is required to produce a ?Dict* return type because `free()` does not accept a `const type*` argument. If it wasn't for this restriction, I would have preferred to create a `const ?Dict*` object to emphasize the fact that, once created, a dictionary never changes (hence can be shared concurrently until the end of its lifetime). There is no such limitation with initStatic?Dict() : as stated in the doc, there is no corresponding free() function, since `workspace` is provided, hence allocated, externally, it can only be free() externally. Which means, ZSTD_initStatic?Dict() can return a `const ZSTD_?Dict*` pointer. Tested with `make all`, to catch initStatic's users, which, incidentally, also updated zstd.h documentation. |
||
---|---|---|
.. | ||
fse_compress.c | ||
huf_compress.c | ||
zstd_compress_internal.h | ||
zstd_compress.c | ||
zstd_double_fast.c | ||
zstd_double_fast.h | ||
zstd_fast.c | ||
zstd_fast.h | ||
zstd_lazy.c | ||
zstd_lazy.h | ||
zstd_ldm.c | ||
zstd_ldm.h | ||
zstd_opt.c | ||
zstd_opt.h | ||
zstdmt_compress.c | ||
zstdmt_compress.h |