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

Method combined_events

crates/vm/src/stdlib/sys/monitoring.rs:117–121  ·  view source on GitHub ↗

Compute the OR of all tools' global_events + local_events. This is used for the fast-path atomic mask to skip monitoring when no events are registered at all.

(&self)

Source from the content-addressed store, hash-verified

115 /// This is used for the fast-path atomic mask to skip monitoring
116 /// when no events are registered at all.
117 pub fn combined_events(&self) -> u32 {
118 let global = self.global_events.iter().fold(0, |acc, &e| acc | e);
119 let local = self.local_events.values().fold(0, |acc, &e| acc | e);
120 global | local
121 }
122
123 /// Compute the events that apply to a specific code object:
124 /// global events OR'd with local events registered for that code.

Callers 1

update_events_maskFunction · 0.80

Calls 3

foldMethod · 0.45
iterMethod · 0.45
valuesMethod · 0.45

Tested by

no test coverage detected