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

Function exit

crates/vm/src/stdlib/_thread.rs:613–615  ·  view source on GitHub ↗
(vm: &VirtualMachine)

Source from the content-addressed store, hash-verified

611
612 #[pyfunction]
613 fn exit(vm: &VirtualMachine) -> PyResult {
614 Err(vm.new_exception_empty(vm.ctx.exceptions.system_exit.to_owned()))
615 }
616
617 thread_local!(static SENTINELS: RefCell<Vec<PyRef<Lock>>> = const { RefCell::new(Vec::new()) });
618

Callers

nothing calls this directly

Calls 3

new_exception_emptyMethod · 0.80
ErrClass · 0.50
to_ownedMethod · 0.45

Tested by

no test coverage detected