mirror of
https://github.com/servo/servo.git
synced 2025-08-06 14:10:11 +01:00
script: Mark callback methods with CanGc. (#35753)
Signed-off-by: Josh Matthews <josh@joshmatthews.net>
This commit is contained in:
parent
3d320fa96a
commit
5650fa2e79
26 changed files with 133 additions and 67 deletions
|
@ -1034,9 +1034,11 @@ impl TestBindingMethods<crate::DomTypeHolder> for TestBinding {
|
|||
}
|
||||
}
|
||||
impl Callback for SimpleHandler {
|
||||
fn callback(&self, cx: SafeJSContext, v: HandleValue, realm: InRealm, _can_gc: CanGc) {
|
||||
fn callback(&self, cx: SafeJSContext, v: HandleValue, realm: InRealm, can_gc: CanGc) {
|
||||
let global = GlobalScope::from_safe_context(cx, realm);
|
||||
let _ = self.handler.Call_(&*global, v, ExceptionHandling::Report);
|
||||
let _ = self
|
||||
.handler
|
||||
.Call_(&*global, v, ExceptionHandling::Report, can_gc);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue