Skip to content

Commit d574826

Browse files
authored
Fix new clippy warnings (#507)
1 parent 9b0a6c2 commit d574826

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

feather/common/src/window.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -196,7 +196,7 @@ impl Window {
196196
}
197197

198198
fn shift_click_in_player_window(&mut self, slot: usize) -> SysResult {
199-
let mut slot_item = &mut *self.inner.item(slot)?;
199+
let slot_item = &mut *self.inner.item(slot)?;
200200

201201
let (inventory, slot_area, _) = self.inner.index_to_slot(slot).unwrap();
202202
let areas_to_try = [
@@ -238,7 +238,7 @@ impl Window {
238238
let mut i = 0;
239239
while let Some(mut stack) = inventory.item(area, i) {
240240
if stack.is_empty() {
241-
stack.merge(&mut slot_item);
241+
stack.merge(slot_item);
242242
}
243243
i += 1;
244244
}

libcraft/text/src/text/markdown/lexer.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,7 @@ impl<'a> InputIter for Tokens<'a> {
139139
where
140140
P: Fn(Self::Item) -> bool,
141141
{
142-
self.tok.iter().position(|b| predicate(b))
142+
self.tok.iter().position(predicate)
143143
}
144144

145145
fn slice_index(&self, count: usize) -> Option<usize> {

0 commit comments

Comments
 (0)