pub struct Data {
pub objects: Vec<Object>,
pub weak: Vec<String>,
}Expand description
The variables a file defines, and what the linker has to be told about them.
One entry per variable rather than one section of everything, because where a variable goes is worked out from what it is and two of them that land in one section still have their own alignment, their own size and their own symbol. Putting them together is the writer’s job and is the one part of it the three formats disagree about.
Fields§
§objects: Vec<Object>Every variable this file defines, in the order the module held them.
weak: Vec<String>Every name this file declares weak and does not define, in the order the module held them.
Each becomes an undefined symbol the linker is allowed to leave undefined, whose references then read a zero address. A name here is not an object and carries no bytes, which is why it is a list of names beside the objects rather than one of them.
Trait Implementations§
impl Eq for Data
impl StructuralPartialEq for Data
Auto Trait Implementations§
impl Freeze for Data
impl RefUnwindSafe for Data
impl Send for Data
impl Sync for Data
impl Unpin for Data
impl UnsafeUnpin for Data
impl UnwindSafe for Data
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.