signum 的文档存在一个小错误。它说
If d is ##Inf or ##-Inf => d
然而,(java.lang.Math/signum d)
对于 #Inf 的输出是 1.0,而对于 #-Inf 的输出是 -1.0。因此,这一行可能可以删除。
但是,如果应该明确描述无穷大,那么
If d is ##Inf => 1.0
If d is ##-Inf => -1.0
next-down
的文档是
Returns the adjacent double of d in the direction of ##-Inf.
If d is ##NaN => ##NaN
If d is ##Inf => ##-Inf
If d is zero => Double/MIN_VALUE
这应该读作
Returns the adjacent double of d in the direction of ##-Inf.
If d is ##NaN => ##NaN
If d is ##Inf => Double/MAX_VALUE
If d is zero => -Double/MIN_VALUE
round
的文档是
Returns the closest long to a. If equally close to two values, return the one
closer to ##Inf.
If a is ##NaN => 0
If a is ##-Inf => ##-Inf
If a is ##Inf => ##Inf
这应该读作
Returns the closest long to a. If equally close to two values, return the one
closer to ##Inf.
If a is ##NaN => 0
If a is ##-Inf => Long/MAX_VALUE
If a is ##Inf => Long/MIN_VALUE