Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(214)

Unified Diff: sdk/lib/core/num.dart

Issue 2541513002: Update documentation for num.clamp. (Closed)
Patch Set: Address comments. Created 4 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sdk/lib/core/num.dart
diff --git a/sdk/lib/core/num.dart b/sdk/lib/core/num.dart
index 21f23eef18321ab7fc4b59aa397cdbb7ead0b0d6..ae9df01afc01f56caa0266efb0951e0e9479b1e7 100644
--- a/sdk/lib/core/num.dart
+++ b/sdk/lib/core/num.dart
@@ -296,6 +296,9 @@ abstract class num implements Comparable<num> {
* The comparison is done using [compareTo] and therefore takes `-0.0` into
* account. This also implies that [double.NAN] is treated as the maximal
* double value.
+ *
+ * The arguments [lowerLimit] and [upperLimit] must form a valid range where
+ * `lowerLimit.compareTo(upperLimit) <= 0`.
*/
num clamp(num lowerLimit, num upperLimit);
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698