#[non_exhaustive]pub enum LoadRefusal {
Show 14 variants
Absent,
PlatformLoader {
detail: String,
},
NotIdentifiable {
detail: String,
},
ResolvedToAnotherFile {
resolved: PathBuf,
},
MissingAnchor {
symbol: &'static CStr,
detail: String,
},
MissingEntryPoint {
symbol: &'static CStr,
},
EntryPointOutsideModule {
symbol: &'static CStr,
module: PathBuf,
},
EditionNotMet,
UnreadableVersion(VersionTextDefect),
AlreadyRefused {
path: PathBuf,
refusal: Box<LoadRefusal>,
},
NoCompleteFileFamily {
first_missing: &'static CStr,
},
BoundToAnotherRuntime,
ForeignRuntimeInScope {
module: PathBuf,
},
RelativeSearchDirectory,
}Expand description
Why a candidate could not provide a usable implementation.
This is a structured diagnostic, not a promise that the platform loader can distinguish an absent bare name from every other loading failure.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Absent
No file exists at an exact directory candidate.
PlatformLoader
The platform loader could not open a location; its diagnostic is retained.
NotIdentifiable
A loaded module or resolved address could not be identified.
ResolvedToAnotherFile
The platform opened another file instead of the requested absolute path.
MissingAnchor
The identification anchor is absent: this file is not the requested library.
Fields
MissingEntryPoint
An identified library lacks an entry point required by the API.
EntryPointOutsideModule
A lookup found the entry point in a dependency instead of the selected module.
Fields
EditionNotMet
The library lacks the entry points identifying the requested Advanced edition.
UnreadableVersion(VersionTextDefect)
The runtime did not return bounded, valid UTF-8 version text.
AlreadyRefused
A loader search returned a module already loaded and refused earlier.
Fields
refusal: Box<LoadRefusal>Why this attempt could not use it.
NoCompleteFileFamily
The File library has no complete family of entry points.
Fields
BoundToAnotherRuntime
The File library’s imports bind to a runtime other than the selected one.
ForeignRuntimeInScope
Another NDI runtime in the global symbol scope would capture this candidate’s native calls. The candidate was not opened.
Applies to dynamically loaded, non-Apple ELF targets. Select the module
named here, or stop linking or preloading it. An explicit runtime path
instead reports SelectionConflict::ForeignRuntimeInScope.
RelativeSearchDirectory
An NDI_RUNTIME_DIR_V6, PATH, DYLD_LIBRARY_PATH or
DYLD_FALLBACK_LIBRARY_PATH directory is relative or empty and was not
opened. LoadAttempt::origin identifies the environment variable.
Trait Implementations§
Source§impl Clone for LoadRefusal
impl Clone for LoadRefusal
Source§impl Debug for LoadRefusal
impl Debug for LoadRefusal
Source§impl Display for LoadRefusal
impl Display for LoadRefusal
impl Eq for LoadRefusal
Source§impl Error for LoadRefusal
impl Error for LoadRefusal
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
use the Display impl or to_string()