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

Function rect

crates/stdlib/src/cmath.rs:40–43  ·  view source on GitHub ↗
(r: ArgIntoFloat, phi: ArgIntoFloat, vm: &VirtualMachine)

Source from the content-addressed store, hash-verified

38
39 #[pyfunction]
40 fn rect(r: ArgIntoFloat, phi: ArgIntoFloat, vm: &VirtualMachine) -> PyResult<Complex64> {
41 pymath::cmath::rect(r.into_float(), phi.into_float())
42 .map_err(|err| pymath_exception(err, vm))
43 }
44
45 #[pyfunction]
46 fn isinf(z: ArgIntoComplex) -> bool {

Callers 1

test_rectMethod · 0.90

Calls 2

pymath_exceptionFunction · 0.85
into_floatMethod · 0.80

Tested by 1

test_rectMethod · 0.72