#[non_exhaustive]pub enum SymbolProblem {
NameContainsNul,
UnknownSection,
OutOfSection,
LocalUndefined,
BadFileSymbol,
BadCommonSymbol,
CommonInExecutable,
UndefinedInExecutable,
TlsOutsideTlsSection,
}Expand description
What is wrong with one symbol. Reported inside ModelError::Symbol.
§Examples
use object_lang::SymbolProblem;
assert_eq!(SymbolProblem::LocalUndefined.to_string(), "a local symbol must be defined");Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
NameContainsNul
The name contains a NUL byte.
UnknownSection
The symbol is defined in a section the object does not have.
OutOfSection
The symbol (its value, or value plus size) lies outside its section.
LocalUndefined
A local symbol is undefined or common: nothing outside the object could define it.
BadFileSymbol
A File symbol is not local and absolute with value
and size zero.
BadCommonSymbol
A Common symbol is not global, or its alignment
(its value) is not a power of two.
CommonInExecutable
A Common symbol in an executable: an
executable’s storage is already allocated.
UndefinedInExecutable
A non-weak undefined symbol in an executable: nothing is left to define it.
TlsOutsideTlsSection
Trait Implementations§
Source§impl Clone for SymbolProblem
impl Clone for SymbolProblem
impl Copy for SymbolProblem
Source§impl Debug for SymbolProblem
impl Debug for SymbolProblem
Source§impl Display for SymbolProblem
impl Display for SymbolProblem
impl Eq for SymbolProblem
Source§impl Hash for SymbolProblem
impl Hash for SymbolProblem
Source§impl PartialEq for SymbolProblem
impl PartialEq for SymbolProblem
impl StructuralPartialEq for SymbolProblem
Auto Trait Implementations§
impl Freeze for SymbolProblem
impl RefUnwindSafe for SymbolProblem
impl Send for SymbolProblem
impl Sync for SymbolProblem
impl Unpin for SymbolProblem
impl UnsafeUnpin for SymbolProblem
impl UnwindSafe for SymbolProblem
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
Mutably borrows from an owned value. Read more