Clarify floor and ceil docs (KT-30418)

This commit is contained in:
Ilya Gorbunov
2019-03-15 19:23:07 +03:00
parent b0a234ec74
commit b74fe7c1c3
3 changed files with 12 additions and 12 deletions
+4 -4
View File
@@ -289,7 +289,7 @@ public actual inline fun ln1p(x: Double): Double = nativeMath.log1p(x)
/**
* Rounds the given value [x] to an integer towards positive infinity.
* @return the smallest double value that is greater than the given value [x] and is a mathematical integer.
* @return the smallest double value that is greater than or equal to the given value [x] and is a mathematical integer.
*
* Special cases:
* - `ceil(x)` is `x` where `x` is `NaN` or `+Inf` or `-Inf` or already a mathematical integer.
@@ -301,7 +301,7 @@ public actual inline fun ceil(x: Double): Double = nativeMath.ceil(x).unsafeCast
/**
* Rounds the given value [x] to an integer towards negative infinity.
* @return the largest double value that is smaller than the given value [x] and is a mathematical integer.
* @return the largest double value that is smaller than or equal to the given value [x] and is a mathematical integer.
*
* Special cases:
* - `floor(x)` is `x` where `x` is `NaN` or `+Inf` or `-Inf` or already a mathematical integer.
@@ -824,7 +824,7 @@ public actual inline fun ln1p(x: Float): Float = nativeMath.log1p(x.toDouble()).
/**
* Rounds the given value [x] to an integer towards positive infinity.
* @return the smallest Float value that is greater than the given value [x] and is a mathematical integer.
* @return the smallest Float value that is greater than or equal to the given value [x] and is a mathematical integer.
*
* Special cases:
* - `ceil(x)` is `x` where `x` is `NaN` or `+Inf` or `-Inf` or already a mathematical integer.
@@ -836,7 +836,7 @@ public actual inline fun ceil(x: Float): Float = nativeMath.ceil(x.toDouble()).t
/**
* Rounds the given value [x] to an integer towards negative infinity.
* @return the largest Float value that is smaller than the given value [x] and is a mathematical integer.
* @return the largest Float value that is smaller than or equal to the given value [x] and is a mathematical integer.
*
* Special cases:
* - `floor(x)` is `x` where `x` is `NaN` or `+Inf` or `-Inf` or already a mathematical integer.