chiark
/
gitweb
/
~ianmdlvl
/
otter.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
4c1235a
)
Replace an open-coded into_unprepared call
author
Ian Jackson
<ijackson@chiark.greenend.org.uk>
Sun, 1 May 2022 01:38:13 +0000
(
02:38
+0100)
committer
Ian Jackson
<ijackson@chiark.greenend.org.uk>
Sun, 1 May 2022 01:38:13 +0000
(
02:38
+0100)
Found this will looking at this code.
Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
daemon/cmdlistener.rs
patch
|
blob
|
history
diff --git
a/daemon/cmdlistener.rs
b/daemon/cmdlistener.rs
index e1fb0b121ab641641824ca98e2eccb64868e988f..6745b26040cd5ea3bbda4bcb93c3cb5533945193 100644
(file)
--- a/
daemon/cmdlistener.rs
+++ b/
daemon/cmdlistener.rs
@@
-1058,13
+1058,7
@@
fn execute_game_insn<'cs, 'igr, 'ig: 'igr>(
}],
raw: None },
Fine,
- if xupdates.len() != 0 {
- vec![
- Box::new(move |prepub: &mut PrepareUpdatesBuffer|
- prepub.piece_updates(xupdates, &None))
- as SomeUnpreparedUpdates
- ]
- } else { default() },
+ xupdates.into_unprepared(None),
vec![],
ig_g)
},