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

Method close

crates/stdlib/src/select.rs:610–616  ·  view source on GitHub ↗
(&self)

Source from the content-addressed store, hash-verified

608
609 #[pymethod]
610 fn close(&self) -> std::io::Result<()> {
611 let fd = self.epoll_fd.write().take();
612 if let Some(fd) = fd {
613 nix::unistd::close(fd.into_raw_fd())?;
614 }
615 Ok(())
616 }
617
618 #[pygetset]
619 fn closed(&self) -> bool {

Callers 1

__exit__Method · 0.45

Calls 4

closeFunction · 0.70
takeMethod · 0.45
writeMethod · 0.45
into_raw_fdMethod · 0.45

Tested by

no test coverage detected