Skip to main content

check_non_negative

Function check_non_negative 

Source
pub fn check_non_negative(value: f64, name: &str) -> PhysicsResult<f64>
Expand description

Returns Ok(value) if value >= 0, otherwise Err(InvalidInput).