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

Function get_user_signal

crates/stdlib/src/faulthandler.rs:1013–1016  ·  view source on GitHub ↗
(signum: usize)

Source from the content-addressed store, hash-verified

1011 static USER_SIGNALS: Mutex<Option<Vec<UserSignal>>> = Mutex::new(None);
1012
1013 pub fn get_user_signal(signum: usize) -> Option<UserSignal> {
1014 let guard = USER_SIGNALS.lock();
1015 guard.as_ref().and_then(|v| v.get(signum).cloned())
1016 }
1017
1018 pub fn set_user_signal(signum: usize, signal: UserSignal) {
1019 let mut guard = USER_SIGNALS.lock();

Callers 2

faulthandler_user_signalFunction · 0.85
registerFunction · 0.85

Calls 3

lockMethod · 0.45
as_refMethod · 0.45
getMethod · 0.45

Tested by

no test coverage detected