pub struct ValidateStep {
pub target: String,
pub rule: String,
pub guard: Option<ConfidenceGuard>,
pub loc: Loc,
}Fields§
§target: String§rule: String§guard: Option<ConfidenceGuard>v2.88.0 — if confidence < 0.8 -> refine(max_attempts: 2), ATTACHED
to the validation it governs.
The guard is a field of the validate rather than a sibling statement,
and the difference is what makes confidence unambiguous BY
CONSTRUCTION. As a sibling, “which confidence does this guard read?”
needs a resolution rule (nearest preceding validate), a compile error
for the zero case, and dispatch-side re-pairing — three places to
drift. As a field there is exactly one validation it can mean, the
pairing survives into the IR untouched, and a guard with no validation
is UNREPRESENTABLE rather than refused.
loc: LocTrait Implementations§
Auto Trait Implementations§
impl Freeze for ValidateStep
impl RefUnwindSafe for ValidateStep
impl Send for ValidateStep
impl Sync for ValidateStep
impl Unpin for ValidateStep
impl UnsafeUnpin for ValidateStep
impl UnwindSafe for ValidateStep
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