Struct boehm::tracing::GcTracing
pub struct GcTracing<T> { // some fields omitted }
A pointer that uses type information to inform the GC about what things could possibly be pointers, and what can just be ignored.
That is, run Boehm in precise-on-the-heap mode.
Fields
Methods
impl<T: BoehmTraced> GcTracing<T>
fn new(value: T) -> GcTracing<T>
Create a new GcTracing.
NB. this extracts the type information at runtime, for each allocation, and so is quite slow.
TODO: fix that (requires compiler hooks)
fn borrow<'r>(&'r self) -> &'r T
Trait Implementations
impl<T: Clone> Clone for GcTracing<T>
Automatically derived.
fn clone(&self) -> GcTracing<T>
impl<T> BoehmTraced for GcTracing<T>
fn indicate_ptr_words(_dummy: Option<GcTracing<T>>, words: &mut [bool])
Mark which words within Self
can possibly hold relevant
pointers (do not explicitly mark which words are not
pointers).
E.g. struct Foo { x: uint, y: GcTracing<uint>, z:
GcTracing<uint> }
should explicitly set words[1]
and
words[2]
to true
but leave words[0]
untouched.
As long as get_tracing_descr
is not overridden,
words
is guaranteed to be large enough to hold all the words
in the current type.
fn get_tracing_descr(dummy: Option<Self>) -> GC_descr
Construct the GC_descr
of Self
. This should not be
overriden.