From c97483dbd3d9eb24a93a3af5f0364b47c18f7bce Mon Sep 17 00:00:00 2001 From: strawberry Date: Sat, 2 Mar 2024 21:02:29 -0500 Subject: [PATCH] fix rocksdb-specific lints Signed-off-by: strawberry --- Cargo.toml | 1 - src/database/abstraction/rocksdb.rs | 6 +++--- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index 946080e4..6c6c20b7 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -223,7 +223,6 @@ elided_lifetimes_in_paths = "warn" macro_use_extern_crate = "warn" single_use_lifetimes = "warn" unsafe_op_in_unsafe_fn = "warn" -unused_tuple_struct_fields = "warn" # not in rust 1.75.0 (doesn't break CI but won't check for it) unit_bindings = "warn" diff --git a/src/database/abstraction/rocksdb.rs b/src/database/abstraction/rocksdb.rs index d51ccefd..2c752a71 100644 --- a/src/database/abstraction/rocksdb.rs +++ b/src/database/abstraction/rocksdb.rs @@ -208,7 +208,7 @@ impl KvTree for RocksDbEngineTree<'_> { self.db .rocks .iterator_cf(&self.cf(), rocksdb::IteratorMode::Start) - .map(|r| r.unwrap()) + .map(std::result::Result::unwrap) .map(|(k, v)| (Vec::from(k), Vec::from(v))), ) } @@ -232,7 +232,7 @@ impl KvTree for RocksDbEngineTree<'_> { }, ), ) - .map(|r| r.unwrap()) + .map(std::result::Result::unwrap) .map(|(k, v)| (Vec::from(k), Vec::from(v))), ) } @@ -273,7 +273,7 @@ impl KvTree for RocksDbEngineTree<'_> { &self.cf(), rocksdb::IteratorMode::From(&prefix, rocksdb::Direction::Forward), ) - .map(|r| r.unwrap()) + .map(std::result::Result::unwrap) .map(|(k, v)| (Vec::from(k), Vec::from(v))) .take_while(move |(k, _)| k.starts_with(&prefix)), )