pub struct Change {
pub bench: String,
pub tool: String,
pub runner: String,
pub metric: String,
pub base: f64,
pub head: f64,
}Expand description
One metric, on one series, on both sides.
Fields§
§bench: String§tool: String§runner: String§metric: String§base: f64§head: f64Implementations§
Source§impl Change
impl Change
Sourcepub fn pct(&self) -> Option<f64>
pub fn pct(&self) -> Option<f64>
Change as a percentage of the base, or None when the base is zero.
None rather than 0.0. Returning zero was worse than imprecise: the
gate compares this against the threshold, so a rise from a zero baseline
read as no change at all and passed silently, however large the head.
A percentage of nothing is undefined, and the type should say so.
Trait Implementations§
impl StructuralPartialEq for Change
Auto Trait Implementations§
impl Freeze for Change
impl RefUnwindSafe for Change
impl Send for Change
impl Sync for Change
impl Unpin for Change
impl UnsafeUnpin for Change
impl UnwindSafe for Change
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