logo
pub enum ElfError {
Show 22 variants FailedToParse(String), EntrypointOutOfBounds, InvalidEntrypoint, FailedToGetSection(String), UnresolvedSymbol(Stringusizeusize), SectionNotFound(String), RelativeJumpOutOfBounds(usize), SymbolHashCollision(u32), WrongEndianess, WrongAbi, WrongMachine, WrongClass, NotOneTextSection, BssNotSupported, WritableSectionNotSupported(String), AddressOutsideLoadableSection(u64), InvalidVirtualAddress(u64), UnknownRelocation(u32), FailedToReadRelocationInfo, WrongType, UnknownSymbol(usize), ValueOutOfBounds,
}
Expand description

Error definitions

Variants

FailedToParse(String)

Failed to parse ELF file

EntrypointOutOfBounds

Entrypoint out of bounds

InvalidEntrypoint

Invaid entrypoint

FailedToGetSection(String)

Failed to get section

UnresolvedSymbol(Stringusizeusize)

Unresolved symbol

SectionNotFound(String)

Section no found

RelativeJumpOutOfBounds(usize)

Relative jump out of bounds

SymbolHashCollision(u32)

Symbol hash collision

WrongEndianess

Incompatible ELF: wrong endianess

WrongAbi

Incompatible ELF: wrong ABI

WrongMachine

Incompatible ELF: wrong mchine

WrongClass

Incompatible ELF: wrong class

NotOneTextSection

Not one text section

BssNotSupported

Read-write data not supported

WritableSectionNotSupported(String)

Read-write data not supported

AddressOutsideLoadableSection(u64)

Relocation failed, no loadable section contains virtual address

InvalidVirtualAddress(u64)

Relocation failed, invalid referenced virtual address

UnknownRelocation(u32)

Relocation failed, unknown type

FailedToReadRelocationInfo

Failed to read relocation info

WrongType

Incompatible ELF: wrong type

UnknownSymbol(usize)

Unknown symbol

ValueOutOfBounds

Offset or value is out of bounds

Trait Implementations

Formats the value using the given formatter. Read more

Formats the value using the given formatter. Read more

The lower-level source of this error, if any. Read more

🔬 This is a nightly-only experimental API. (backtrace)

Returns a stack backtrace, if available, of where this error occurred. Read more

👎 Deprecated since 1.42.0:

use the Display impl or to_string()

👎 Deprecated since 1.33.0:

replaced by Error::source, which can support downcasting

Performs the conversion.

Performs the conversion.

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Performs the conversion.

Performs the conversion.

Converts the given value to a String. Read more

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.