(string1: PyUtf8StrRef, string2: PyUtf8StrRef, vm: &VirtualMachine)
| 150 | |
| 151 | #[pyfunction] |
| 152 | fn strcoll(string1: PyUtf8StrRef, string2: PyUtf8StrRef, vm: &VirtualMachine) -> PyResult { |
| 153 | let cstr1 = CString::new(string1.as_str()).map_err(|e| e.to_pyexception(vm))?; |
| 154 | let cstr2 = CString::new(string2.as_str()).map_err(|e| e.to_pyexception(vm))?; |
| 155 | Ok(vm.new_pyobj(unsafe { libc::strcoll(cstr1.as_ptr(), cstr2.as_ptr()) })) |
| 156 | } |
| 157 | |
| 158 | #[pyfunction] |
| 159 | fn strxfrm(string: PyUtf8StrRef, vm: &VirtualMachine) -> PyResult { |
nothing calls this directly
no test coverage detected