Fix cargo test and a number of little cleanup bugs

This commit is contained in:
Jonathan Kelley committed 2024-01-30 17:33:14 -08:00
1 parent eff1dd6c90
commit 0bd9692e45
49 files changed
+307 -309

No files matched your search

+2
View File
@@ -45,10 +45,12 @@ impl Task {
Runtime::with(|rt| !rt.tasks.borrow()[self.0].active.get()).unwrap_or_default()
}
/// Wake the task.
pub fn wake(&self) {
Runtime::with(|rt| _ = rt.sender.unbounded_send(SchedulerMsg::TaskNotified(*self)));
}
/// Set the task as active or paused.
pub fn set_active(&self, active: bool) {
Runtime::with(|rt| rt.tasks.borrow()[self.0].active.set(active));
}