Struct crate_metadata::WeakDependent
source · pub struct WeakDependent {
pub section: WeakSectionRef,
pub relocation: RelocationEntry,
}
Expand description
A representation that the section
A
in this struct
depends on the owner B
of (the LoadedSection
object containing) this struct.
The target dependency B
is not specifically included here;
it’s implicitly the owner of this struct.
This is a weak reference to another LoadedSection
A
,
because it is okay to remove a section A
that depends on the owning section B
before removing B
.
Otherwise, there would be an infinitely recursive dependency, and neither A
nor B
could ever be dropped.
This design allows for A
to be dropped before B
, because there is no dependency ordering violation there.
This is the inverse of the StrongDependency
type.
Fields§
§section: WeakSectionRef
A weak reference to the LoadedSection
A
that depends on the owner B
of this struct.
relocation: RelocationEntry
The details of the relocation action that was performed.
Trait Implementations§
source§impl Clone for WeakDependent
impl Clone for WeakDependent
source§fn clone(&self) -> WeakDependent
fn clone(&self) -> WeakDependent
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read more