Improve documentation comments
Remove passive voice from documentation comments.
This commit is contained in:
parent
17665ec50d
commit
c78a48fd35
|
@ -243,8 +243,9 @@ float_trait_impl!(Num for f32 f64);
|
||||||
|
|
||||||
/// A value bounded by a minimum and a maximum
|
/// A value bounded by a minimum and a maximum
|
||||||
///
|
///
|
||||||
/// If input is less than min then min is returned, if input is greater than max then max is
|
/// If input is less than min then this returns min.
|
||||||
/// returned. Otherwise input is returned.
|
/// If input is greater than max then this returns max.
|
||||||
|
/// Otherwise this returns input.
|
||||||
#[inline]
|
#[inline]
|
||||||
pub fn clamp<T: PartialOrd>(input: T, min: T, max: T) -> T {
|
pub fn clamp<T: PartialOrd>(input: T, min: T, max: T) -> T {
|
||||||
debug_assert!(min <= max, "min must be less than or equal to max");
|
debug_assert!(min <= max, "min must be less than or equal to max");
|
||||||
|
|
Loading…
Reference in New Issue