feat(dict): port the public zdict builder to Rust
Move the public ZDICT helpers, legacy trainer, dictionary finalization, entropy-table construction, and supporting dictionary logic into Rust. Keep the C translation unit as an ABI anchor and register the Rust module only when compression and dictionary-builder features are enabled. Test Plan: - RUSTC_WRAPPER= CARGO_BUILD_RUSTC_WRAPPER= cargo test --manifest-path rust/Cargo.toml dict_builder_zdict - RUSTC_WRAPPER= CARGO_BUILD_RUSTC_WRAPPER= cargo clippy --manifest-path rust/Cargo.toml --all-targets -- -D warnings - rustfmt +nightly --check --edition 2021 rust/src/dict_builder_zdict.rs rust/src/lib.rs - git diff --cached --check
This commit is contained in:
+4
-2
@@ -6,6 +6,10 @@ pub mod common;
|
||||
pub mod cpu;
|
||||
pub mod debug;
|
||||
#[cfg(feature = "dict-builder")]
|
||||
pub mod dict_builder_cover;
|
||||
#[cfg(all(feature = "compression", feature = "dict-builder"))]
|
||||
pub mod dict_builder_zdict;
|
||||
#[cfg(feature = "dict-builder")]
|
||||
pub mod divsufsort;
|
||||
pub mod entropy_common;
|
||||
pub mod errors;
|
||||
@@ -18,8 +22,6 @@ pub mod hist;
|
||||
pub mod huf_compress;
|
||||
#[cfg(feature = "decompression")]
|
||||
pub mod huf_decompress;
|
||||
#[cfg(feature = "dict-builder")]
|
||||
pub mod dict_builder_cover;
|
||||
pub mod legacy;
|
||||
pub mod mem;
|
||||
pub mod pool;
|
||||
|
||||
Reference in New Issue
Block a user