pub(super) fn pop_all(&self) -> Option<usize> { let val = self.head.swap(super::Addr::<C>::NULL, Ordering::Acquire);
test_println!("-> pop {:#x}", val); if val == super::Addr::<C>::NULL {
None
} else {
Some(val)
}
}
fn push(&self, new_head: usize, before: implFn(usize)) { // We loop to win the race to set the new head. The `next` variable // is the next slot on the stack which needs to be pointed to by the // new head. letmut next = self.head.load(Ordering::Relaxed); loop {
test_println!("-> next {:#x}", next);
before(next);
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.