diff options
Diffstat (limited to 'components/script/dom/macros.rs')
-rw-r--r-- | components/script/dom/macros.rs | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/components/script/dom/macros.rs b/components/script/dom/macros.rs index 57966e37ae6..d3c157cf134 100644 --- a/components/script/dom/macros.rs +++ b/components/script/dom/macros.rs @@ -266,6 +266,14 @@ macro_rules! make_nonzero_dimension_setter( /// For use on non-jsmanaged types /// Use #[derive(JSTraceable)] on JS managed types macro_rules! no_jsmanaged_fields( + ([$ty:ident; $count:expr]) => ( + impl $crate::dom::bindings::trace::JSTraceable for [$ty; $count] { + #[inline] + fn trace(&self, _: *mut ::js::jsapi::JSTracer) { + // Do nothing + } + } + ); ($($ty:ident),+) => ( $( impl $crate::dom::bindings::trace::JSTraceable for $ty { |