Skip to content

Commit 962f8f7

Browse files
committed
Remove another clone, fix clippy
1 parent 67ab1c3 commit 962f8f7

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

core/mvcc/cursor.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -368,7 +368,7 @@ impl<Clock: LogicalClock + 'static> MvccLazyCursor<Clock> {
368368
MvccCursorType::Table => None,
369369
};
370370
self.db
371-
.read_from_table_or_index(self.tx_id, &row_id, maybe_index_id)
371+
.read_from_table_or_index(self.tx_id, row_id, maybe_index_id)
372372
}
373373

374374
pub fn close(self) -> Result<()> {
@@ -1485,7 +1485,7 @@ impl<Clock: LogicalClock + 'static> CursorTrait for MvccLazyCursor<Clock> {
14851485

14861486
fn count(&mut self) -> Result<IOResult<usize>> {
14871487
loop {
1488-
let state = self.count_state.clone();
1488+
let state = self.count_state;
14891489
match state {
14901490
None => {
14911491
self.count_state.replace(CountState::Rewind);

core/mvcc/database/tests.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1940,7 +1940,7 @@ fn test_delete_nonexistent() {
19401940
.mvcc_store
19411941
.delete(
19421942
tx,
1943-
&RowID {
1943+
RowID {
19441944
table_id: (-2).into(),
19451945
row_id: RowKey::Int(1)
19461946
},
@@ -2161,7 +2161,7 @@ fn test_dirty_read_deleted() {
21612161
.mvcc_store
21622162
.delete(
21632163
tx2,
2164-
&RowID {
2164+
RowID {
21652165
table_id: (-2).into(),
21662166
row_id: RowKey::Int(1)
21672167
},

0 commit comments

Comments
 (0)