(&self)
| 93 | } |
| 94 | |
| 95 | pub fn clear_data(&self) { |
| 96 | let old_data = self.data.swap(ptr::null_mut(), Ordering::SeqCst); |
| 97 | if !old_data.is_null() { |
| 98 | unsafe { |
| 99 | drop(Box::from_raw(old_data)); |
| 100 | } |
| 101 | } |
| 102 | } |
| 103 | |
| 104 | pub fn is_ready(&self) -> bool { |
| 105 | !self.data.load(Ordering::Acquire).is_null() |
nothing calls this directly
no outgoing calls
no test coverage detected