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

Method into_cstring

crates/vm/src/ospath.rs:250–252  ·  view source on GitHub ↗
(self, vm: &VirtualMachine)

Source from the content-addressed store, hash-verified

248 }
249
250 pub fn into_cstring(self, vm: &VirtualMachine) -> PyResult<alloc::ffi::CString> {
251 alloc::ffi::CString::new(self.into_bytes()).map_err(|err| err.to_pyexception(vm))
252 }
253
254 #[cfg(windows)]
255 pub fn to_wide_cstring(&self, vm: &VirtualMachine) -> PyResult<widestring::WideCString> {

Callers 15

from_unistd_groupMethod · 0.80
try_from_objectMethod · 0.80
fromMethod · 0.80
initMethod · 0.80
symlinkFunction · 0.80
removeFunction · 0.80
_mknodMethod · 0.80
mknodMethod · 0.80
lchmodFunction · 0.80
execvFunction · 0.80
execveFunction · 0.80
spawnMethod · 0.80

Calls 3

newFunction · 0.85
into_bytesMethod · 0.45
to_pyexceptionMethod · 0.45

Tested by

no test coverage detected