get elseware to compile on latest rust
This commit is contained in:
parent
1f7dd1eafe
commit
16041640c2
@ -1,12 +1,11 @@
|
|||||||
#![allow(clippy::type_complexity)]
|
#![allow(clippy::type_complexity)]
|
||||||
#![allow(incomplete_features)]
|
#![allow(incomplete_features)]
|
||||||
#![feature(inline_const)]
|
#![feature(inline_const)]
|
||||||
#![feature(drain_filter)]
|
#![feature(extract_if)]
|
||||||
#![feature(try_blocks)]
|
#![feature(try_blocks)]
|
||||||
#![feature(once_cell)]
|
|
||||||
#![feature(test)]
|
#![feature(test)]
|
||||||
#![feature(error_generic_member_access)]
|
#![feature(error_generic_member_access)]
|
||||||
#![feature(provide_any)]
|
#![feature(lazy_cell)]
|
||||||
|
|
||||||
extern crate test;
|
extern crate test;
|
||||||
|
|
||||||
|
@ -96,13 +96,13 @@ pub struct FloorState {
|
|||||||
impl FloorState {
|
impl FloorState {
|
||||||
pub fn take_item(&mut self, item_id: &ClientItemId) -> Option<FloorItem> {
|
pub fn take_item(&mut self, item_id: &ClientItemId) -> Option<FloorItem> {
|
||||||
let item = self.local.0
|
let item = self.local.0
|
||||||
.drain_filter(|item| {
|
.extract_if(|item| {
|
||||||
item.item_id == *item_id
|
item.item_id == *item_id
|
||||||
})
|
})
|
||||||
.next();
|
.next();
|
||||||
item.or_else(|| {
|
item.or_else(|| {
|
||||||
self.shared.0
|
self.shared.0
|
||||||
.drain_filter(|item| {
|
.extract_if(|item| {
|
||||||
item.item_id == *item_id
|
item.item_id == *item_id
|
||||||
})
|
})
|
||||||
.next()
|
.next()
|
||||||
|
Loading…
x
Reference in New Issue
Block a user