Std.Math.clamp
1 declaration
fn
clamp: T -> T -> T -> T where T: OrdThis is a callable function.
What it does
Confine a value to a range, inclusive at both ends.
A range whose lower bound exceeds its upper yields the lower bound, which is
the only answer that satisfies neither caller silently.
Read the signature
- The text after the name is the type checked by Pudu.
- Read arrows from left to right: inputs come first, and the final type is returned.
