Type Alias object::build::elf::Sections

source ·
pub type Sections<'data> = Table<Section<'data>>;
Expand description

A section table.

Aliased Type§

struct Sections<'data>(/* private fields */);

Implementations§

source§

impl<'data> Sections<'data>

source

pub fn add(&mut self) -> &mut Section<'data>

Add a new section to the table.

source

pub fn copy(&mut self, id: SectionId) -> &mut Section<'data>

Add a copy of a section to the table.

This will set the file offset of the copy to zero. Segment::append_section can be used to assign a valid file offset and a new address.