Module

Struct Module 

Source
pub struct Module {
    pub default_func_prefix: String,
    pub default_data_prefix: String,
    pub default_sinit_prefix: String,
    /* private fields */
}

Fields§

§default_func_prefix: String§default_data_prefix: String§default_sinit_prefix: String

Implementations§

Source§

impl Module

Source

pub fn new( symbol_map: &mut SymbolMap, options: ModuleOptions<'_>, ) -> Result<Module, ModuleError>

Source

pub fn new_arm9( name: String, symbol_map: &mut SymbolMap, relocations: Relocations, sections: Sections, code: &[u8], ) -> Result<Module, ModuleError>

👎Deprecated

Depricated, use Self::new instead.

Creates a new ARM9 main module.

Source

pub fn analyze_arm9( arm9: &Arm9<'_>, unknown_autoloads: &[&Autoload<'_>], symbol_maps: &mut SymbolMaps, options: &AnalysisOptions, ) -> Result<Self, ModuleError>

Source

pub fn new_overlay( name: String, symbol_map: &mut SymbolMap, relocations: Relocations, sections: Sections, options: OverlayModuleOptions<'_>, ) -> Result<Self, ModuleError>

👎Deprecated

Depricated, use Self::new instead.

Creates a new overlay module.

Source

pub fn analyze_overlay( overlay: &Overlay<'_>, symbol_maps: &mut SymbolMaps, options: &AnalysisOptions, ) -> Result<Self, ModuleError>

Source

pub fn new_autoload( name: String, symbol_map: &mut SymbolMap, relocations: Relocations, sections: Sections, kind: AutoloadKind, code: &[u8], ) -> Result<Self, ModuleError>

👎Deprecated

Depricated, use Self::new instead.

Creates a new autoload module.

Source

pub fn analyze_itcm( autoload: &Autoload<'_>, symbol_maps: &mut SymbolMaps, options: &AnalysisOptions, ) -> Result<Self, ModuleError>

Source

pub fn analyze_dtcm( autoload: &Autoload<'_>, symbol_maps: &mut SymbolMaps, options: &AnalysisOptions, ) -> Result<Self, ModuleError>

Source

pub fn analyze_unknown_autoload( autoload: &Autoload<'_>, symbol_maps: &mut SymbolMaps, options: &AnalysisOptions, ) -> Result<Self, ModuleError>

Source

pub fn relocations(&self) -> &Relocations

Source

pub fn relocations_mut(&mut self) -> &mut Relocations

Source

pub fn sections(&self) -> &Sections

Source

pub fn sections_mut(&mut self) -> &mut Sections

Source

pub fn code(&self) -> &[u8]

Source

pub fn base_address(&self) -> u32

Source

pub fn end_address(&self) -> u32

Source

pub fn get_function(&self, addr: u32) -> Option<&Function>

Source

pub fn bss_size(&self) -> u32

Source

pub fn name(&self) -> &str

Source

pub fn kind(&self) -> ModuleKind

Source

pub fn signed(&self) -> bool

Auto Trait Implementations§

§

impl Freeze for Module

§

impl RefUnwindSafe for Module

§

impl Send for Module

§

impl Sync for Module

§

impl Unpin for Module

§

impl UnwindSafe for Module

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.