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

Method getsockname

crates/stdlib/src/socket.rs:2195–2199  ·  view source on GitHub ↗
(&self, vm: &VirtualMachine)

Source from the content-addressed store, hash-verified

2193
2194 #[pymethod]
2195 fn getsockname(&self, vm: &VirtualMachine) -> std::io::Result<PyObjectRef> {
2196 let addr = self.sock()?.local_addr()?;
2197
2198 Ok(get_addr_tuple(&addr, vm))
2199 }
2200
2201 #[pymethod]
2202 fn getpeername(&self, vm: &VirtualMachine) -> std::io::Result<PyObjectRef> {

Callers

nothing calls this directly

Calls 2

get_addr_tupleFunction · 0.85
sockMethod · 0.80

Tested by

no test coverage detected