Use JSTraceable everywhere

This commit is contained in:
Manish Goregaokar 2014-09-24 03:01:03 +05:30
parent 85f79290a6
commit cc44a3b064
133 changed files with 325 additions and 278 deletions

View file

@ -2,8 +2,6 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#![macro_escape]
#[macro_export]
macro_rules! make_getter(
( $attr:ident ) => (
@ -48,7 +46,7 @@ macro_rules! make_uint_getter(
/// Use #[jstraceable] on JS managed types
macro_rules! untraceable(
($($ty:ident),+) => (
$(
$(
impl JSTraceable for $ty {
#[inline]
fn trace(&self, _: *mut JSTracer) {
@ -57,4 +55,12 @@ macro_rules! untraceable(
}
)+
);
($ty:ident<$($gen:ident),+>) => (
impl<$($gen),+> JSTraceable for $ty<$($gen),+> {
#[inline]
fn trace(&self, _: *mut JSTracer) {
// Do nothing
}
}
);
)