1
This commit is contained in:
parent
9761c32056
commit
a3415fcd42
@ -22,11 +22,11 @@ impl<T> Queue<T> {
|
||||
return this;
|
||||
}
|
||||
|
||||
pub fn push(&mut self, node: &Rc::<RefCell::<crate::ListHead<T>>>) {
|
||||
pub fn push(&self, node: &Rc::<RefCell::<crate::ListHead<T>>>) {
|
||||
crate::ListHead::<T>::add_tail(&self.msg_list, node);
|
||||
}
|
||||
|
||||
pub fn fetch(&mut self) {
|
||||
pub fn fetch(&self) {
|
||||
if !self.msg_list.borrow().empty() &&
|
||||
self.work_list.borrow().empty() {
|
||||
crate::ListHead::replace_init(&self.work_list, &self.msg_list);
|
||||
|
Loading…
x
Reference in New Issue
Block a user