chore: remove batch_insert feature & make it default

This commit is contained in:
Magamedrasul Ibragimov 2023-01-27 15:07:35 +04:00
parent 75aa714030
commit f369d08b91
3 changed files with 5 additions and 12 deletions

View File

@ -3,12 +3,12 @@ name = "pmtree"
version = "0.1.0"
edition = "2021"
[features]
batch_insert = []
[dev-dependencies]
hex-literal = "0.3.4"
tiny-keccak = { version = "2.0.2", features = ["keccak"] }
sled = "0.34.7"
rln = { git = "https://github.com/vacp2p/zerokit", rev = "490206a" }
ark-serialize = "0.3.0"
ark-serialize = "0.3.0"
[dependencies]
rayon = { version = "1.6.1", optional = false }

View File

@ -16,12 +16,6 @@
pmtree = { git = "https://github.com/Rate-Limiting-Nullifier/pmtree" }
```
To use batch insertions you must enable `batch_insert` feature:
```toml
[dependencies]
pmtree = { git = "https://github.com/Rate-Limiting-Nullifier/pmtree", features = ["batch_insert"] }
```
## Example
In-Memory DB (HashMap) + Keccak

View File

@ -194,9 +194,8 @@ where
}
/// Batch insertion, updates the tree in parallel.
/// Only available as a feature
#[cfg(feature = "batch_insert")]
pub fn batch_insert(&mut self, leaves: &[H::Fr]) -> Result<()> {
// if leaves.len()
Ok(())
}