pub enum ParamError {
TauOutOfRange(f64),
ResyncKZero,
GapOpenNotPositive(f64),
GapExtNotPositive(f64),
GapExtExceedsOpen {
gap_open: f64,
gap_ext: f64,
},
StepsExceedMax {
steps: usize,
max: usize,
},
}Expand description
Why a parameter set was rejected. One variant per violated invariant, carrying the value so the message can be honest about what was seen.
Variants§
TauOutOfRange(f64)
tau must be finite and within [0, 1] (the cost-model scale).
ResyncKZero
resync_k must be at least 1.
GapOpenNotPositive(f64)
gap_open must be finite and positive.
GapExtNotPositive(f64)
gap_ext must be finite and positive.
GapExtExceedsOpen
gap_ext must not exceed gap_open (the affine-gap premise).
StepsExceedMax
A run is longer than max_steps, the guard on the aligner’s O(n·m) allocation
(issue #23). Raised by the engine at align() time, not at validation time, because
it depends on the input, not the params alone.
Trait Implementations§
Source§impl Clone for ParamError
impl Clone for ParamError
Source§fn clone(&self) -> ParamError
fn clone(&self) -> ParamError
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 ParamError
Source§impl Debug for ParamError
impl Debug for ParamError
Source§impl Display for ParamError
impl Display for ParamError
Source§impl Error for ParamError
impl Error for ParamError
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0:
use the Display impl or to_string()
Source§impl PartialEq for ParamError
impl PartialEq for ParamError
impl StructuralPartialEq for ParamError
Auto Trait Implementations§
impl Freeze for ParamError
impl RefUnwindSafe for ParamError
impl Send for ParamError
impl Sync for ParamError
impl Unpin for ParamError
impl UnsafeUnpin for ParamError
impl UnwindSafe for ParamError
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