MCPcopy Index your code
hub / github.com/RustPython/RustPython / _is_zero

Method _is_zero

crates/stdlib/src/multiprocessing.rs:315–319  ·  view source on GitHub ↗
(&self, vm: &VirtualMachine)

Source from the content-addressed store, hash-verified

313
314 #[pymethod]
315 fn _is_zero(&self, vm: &VirtualMachine) -> PyResult<bool> {
316 let val =
317 get_semaphore_value(self.handle.as_raw()).map_err(|_| vm.new_last_os_error())?;
318 Ok(val == 0)
319 }
320
321 #[extend_class]
322 fn extend_class(ctx: &Context, class: &Py<PyType>) {

Callers 5

fullMethod · 0.80
task_doneMethod · 0.80
joinMethod · 0.80
__repr__Method · 0.80
__repr__Method · 0.80

Calls 7

get_semaphore_valueFunction · 0.85
os_errorFunction · 0.85
new_last_os_errorMethod · 0.80
ErrClass · 0.50
as_rawMethod · 0.45
_get_valueMethod · 0.45
as_ptrMethod · 0.45

Tested by

no test coverage detected