pub struct Sym {
pub st_name: usize,
pub st_info: u8,
pub st_other: u8,
pub st_shndx: usize,
pub st_value: u64,
pub st_size: u64,
}
Expand description
A unified Sym definition - convertible to and from 32-bit and 64-bit variants
Fields
st_name: usize
st_info: u8
st_other: u8
st_shndx: usize
st_value: u64
st_size: u64
Implementations
sourceimpl Sym
impl Sym
pub fn size(container: Container) -> usize
sourcepub fn is_import(&self) -> bool
pub fn is_import(&self) -> bool
Checks whether this Sym
has STB_GLOBAL
/STB_WEAK
bind and a st_value
of 0
sourcepub fn is_function(&self) -> bool
pub fn is_function(&self) -> bool
Checks whether this Sym
has type STT_FUNC
sourcepub fn st_visibility(&self) -> u8
pub fn st_visibility(&self) -> u8
Get the ST visibility.
This is the last three bits of the “other” byte.
Trait Implementations
sourceimpl<'a> TryFromCtx<'a, Ctx, [u8]> for Sym
impl<'a> TryFromCtx<'a, Ctx, [u8]> for Sym
sourceimpl TryIntoCtx<Ctx, [u8]> for Sym
impl TryIntoCtx<Ctx, [u8]> for Sym
impl Copy for Sym
impl StructuralPartialEq for Sym
Auto Trait Implementations
impl RefUnwindSafe for Sym
impl Send for Sym
impl Sync for Sym
impl Unpin for Sym
impl UnwindSafe for Sym
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more