diff options
Diffstat (limited to 'components/script/dom/eventtarget.rs')
-rw-r--r-- | components/script/dom/eventtarget.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/components/script/dom/eventtarget.rs b/components/script/dom/eventtarget.rs index 43a0a3502a3..426752e42d5 100644 --- a/components/script/dom/eventtarget.rs +++ b/components/script/dom/eventtarget.rs @@ -34,7 +34,7 @@ use dom::virtualmethods::VirtualMethods; use dom::window::Window; use dom_struct::dom_struct; use fnv::FnvHasher; -use js::jsapi::{CompileFunction, JS_GetFunctionObject, JSAutoCompartment}; +use js::jsapi::{CompileFunction, JS_GetFunctionObject, JSAutoCompartment, JSFunction}; use js::rust::{AutoObjectVectorWrapper, CompileOptionsWrapper}; use libc::{c_char, size_t}; use servo_atoms::Atom; @@ -443,7 +443,7 @@ impl EventTarget { let scopechain = AutoObjectVectorWrapper::new(cx); let _ac = JSAutoCompartment::new(cx, window.reflector().get_jsobject().get()); - rooted!(in(cx) let mut handler = ptr::null_mut()); + rooted!(in(cx) let mut handler = ptr::null_mut::<JSFunction>()); let rv = unsafe { CompileFunction(cx, scopechain.ptr, |