Update toolchain to nightly 08-01

This commit is contained in:
Zhang Junyang
2023-08-02 12:11:42 +08:00
committed by Tate, Hongliang Tian
parent e6f13a0612
commit 5cf624f9ac
7 changed files with 9 additions and 11 deletions

View File

@ -290,7 +290,7 @@ impl Drop for EpollFile {
trace!("EpollFile Drop");
let mut interest = self.interest.lock();
let fds: Vec<_> = interest
.drain_filter(|_, _| true)
.extract_if(|_, _| true)
.map(|(fd, entry)| {
entry.set_deleted();
if let Some(file) = entry.file() {

View File

@ -175,7 +175,7 @@ impl Drop for Poller {
}
let self_observer = self.observer();
for (weak_pollee, _) in pollees.drain_filter(|_, _| true) {
for (weak_pollee, _) in pollees.extract_if(|_, _| true) {
if let Some(pollee) = weak_pollee.upgrade() {
pollee.subject.unregister_observer(&self_observer);
}

View File

@ -4,9 +4,8 @@
#![allow(dead_code)]
#![allow(incomplete_features)]
#![allow(unused_variables)]
#![feature(cstr_from_bytes_until_nul)]
#![feature(exclusive_range_pattern)]
#![feature(btree_drain_filter)]
#![feature(btree_extract_if)]
#![feature(const_option)]
#![feature(extend_one)]
#![feature(let_chains)]

View File

@ -278,7 +278,7 @@ impl Process {
// move children to the init process
if !self.is_init_process() {
if let Some(init_process) = get_init_process() {
for (_, child_process) in self.children.lock().drain_filter(|_, _| true) {
for (_, child_process) in self.children.lock().extract_if(|_, _| true) {
child_process.set_parent(Arc::downgrade(&init_process));
init_process.add_child(child_process);
}