Code Room
Code reviewHard
Question
Review this Rust event registration. `Widget` registers a callback that reads its own `label`.
What a strong answer looks like
Separate real bugs from style. Rank issues by severity, point at the root cause rather than the symptom, and suggest a concrete fix — specific and kind.
Learn the concepts
struct Widget { label: String } impl Widget { fn register(&self, bus: &mut EventBus) { bus.on_click(Box::new(|| { println!("clicked {}", self.label); // borrows self })); }}// bus: on_click(&mut self, cb: Box<dyn Fn() + 'static>)Run or narrate your approach, then ask the coach.