#[non_exhaustive]pub enum NonFiniteLocation {
#[non_exhaustive] MatrixCell {
row: usize,
col: usize,
},
#[non_exhaustive] VectorEntry {
index: usize,
},
#[non_exhaustive] Step {
index: usize,
},
Scalar,
}Expand description
Location at which a non-finite value was observed.
§Examples
use la_stack::prelude::*;
match LaError::non_finite_input_matrix(1, 2) {
LaError::NonFinite {
location: NonFiniteLocation::MatrixCell { row, col, .. },
..
} => assert_eq!((row, col), (1, 2)),
_ => unreachable!("constructor returns a matrix-cell location"),
}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.
#[non_exhaustive]MatrixCell
Cell (row, col) in matrix-shaped storage or computation.
Fields
This variant is marked as non-exhaustive
Non-exhaustive enum variants could have additional fields added in future. Therefore, non-exhaustive enum variants cannot be constructed in external crates and cannot be matched against.
#[non_exhaustive]VectorEntry
Entry in a vector input.
Fields
This variant is marked as non-exhaustive
Non-exhaustive enum variants could have additional fields added in future. Therefore, non-exhaustive enum variants cannot be constructed in external crates and cannot be matched against.
#[non_exhaustive]Step
Indexed step in a factorization, solve, or reduction.
Fields
This variant is marked as non-exhaustive
Non-exhaustive enum variants could have additional fields added in future. Therefore, non-exhaustive enum variants cannot be constructed in external crates and cannot be matched against.
Scalar
Scalar value without a meaningful matrix or vector coordinate.
Trait Implementations§
Source§impl Clone for NonFiniteLocation
impl Clone for NonFiniteLocation
Source§fn clone(&self) -> NonFiniteLocation
fn clone(&self) -> NonFiniteLocation
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for NonFiniteLocation
Source§impl Debug for NonFiniteLocation
impl Debug for NonFiniteLocation
impl Eq for NonFiniteLocation
Source§impl PartialEq for NonFiniteLocation
impl PartialEq for NonFiniteLocation
impl StructuralPartialEq for NonFiniteLocation
Auto Trait Implementations§
impl Freeze for NonFiniteLocation
impl RefUnwindSafe for NonFiniteLocation
impl Send for NonFiniteLocation
impl Sync for NonFiniteLocation
impl Unpin for NonFiniteLocation
impl UnsafeUnpin for NonFiniteLocation
impl UnwindSafe for NonFiniteLocation
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