pub trait Rootable: Traceable + Sized {
const VTABLE: RootedVFTable = _;
// Provided method
unsafe extern "C" fn trace(
this: *mut c_void,
trc: *mut JSTracer,
_name: *const c_char,
) { ... }
}
Expand description
Marker trait that allows any type that implements the [trace::Traceable] trait to be used with the Rooted type.
Rooted<T>
relies on dynamic dispatch in C++ when T uses the Traceable RootKind.
This trait initializes the vtable when creating a Rust instance of the Rooted object.
Provided Associated Constants§
const VTABLE: RootedVFTable = _
Provided Methods§
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.