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

Method new_key_error

crates/vm/src/vm/vm_new.rs:324–327  ·  view source on GitHub ↗

TODO: don't take ownership should make the success path faster

(&self, obj: PyObjectRef)

Source from the content-addressed store, hash-verified

322
323 // TODO: don't take ownership should make the success path faster
324 pub fn new_key_error(&self, obj: PyObjectRef) -> PyBaseExceptionRef {
325 let key_error = self.ctx.exceptions.key_error.to_owned();
326 self.new_exception(key_error, vec![obj])
327 }
328
329 #[cfg(any(feature = "parser", feature = "compiler"))]
330 pub fn new_syntax_error_maybe_incomplete(

Callers 15

modifyMethod · 0.80
unregisterMethod · 0.80
__getitem__Method · 0.80
getgrgidFunction · 0.80
getgrnamFunction · 0.80
lookupMethod · 0.80
formatFunction · 0.80
deleteMethod · 0.80
import_module_levelFunction · 0.80
execute_instructionMethod · 0.80
getpwnamFunction · 0.80
getpwuidFunction · 0.80

Calls 2

new_exceptionMethod · 0.80
to_ownedMethod · 0.45

Tested by

no test coverage detected