#[non_exhaustive]pub enum LoadDefect {
UnknownEffect,
InvalidText,
OutOfBoundsValue,
OutOfBoundsPtr,
}Expand description
TODO: https://users.rust-lang.org/t/validation-monad/117894/6
this is a way cleaner and nicer approach. Provice a lot of data about the Error, like position in file, expected value, received value, … maybe even allow to cancel the parsing via ControlFlow<(), ()>
load was partially successful. These are the defects that are in the now loaded project
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.
UnknownEffect
deletes the effect
InvalidText
replaced with empty text
OutOfBoundsValue
tries to replace with a sane default value
OutOfBoundsPtr
skips loading of the pointed to value
Trait Implementations§
Source§impl Clone for LoadDefect
impl Clone for LoadDefect
Source§fn clone(&self) -> LoadDefect
fn clone(&self) -> LoadDefect
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for LoadDefect
impl Debug for LoadDefect
impl Copy for LoadDefect
Auto Trait Implementations§
impl Freeze for LoadDefect
impl RefUnwindSafe for LoadDefect
impl Send for LoadDefect
impl Sync for LoadDefect
impl Unpin for LoadDefect
impl UnwindSafe for LoadDefect
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