mirror of https://github.com/mkerrisk/man-pages
ffix
This commit is contained in:
parent
56d22987d2
commit
fe93e6770c
|
@ -7,18 +7,25 @@ signbit \- test sign of a real floating point number
|
|||
.SH SYNOPSIS
|
||||
.B "#include <math.h>"
|
||||
.sp
|
||||
.BI "int signbit(" X ");"
|
||||
.BI "int signbit(" x ");"
|
||||
.sp
|
||||
Compile with \fI\-std=c99\fP; link with \fI\-lm\fP.
|
||||
.SH DESCRIPTION
|
||||
`signbit' is a generic macro which can work on all real floating-point
|
||||
types.
|
||||
It returns a non-zero value if the value of X has its sign bit set.
|
||||
.BR signbit ()
|
||||
is a generic macro which can work on all real floating-point types.
|
||||
It returns a non-zero value if the value of
|
||||
.I x
|
||||
has its sign bit set.
|
||||
.PP
|
||||
This is not the same as `x < 0.0', because IEEE 754 floating point
|
||||
This is not the same as
|
||||
.IR "x < 0.0" ,
|
||||
because IEEE 754 floating point
|
||||
allows zero to be signed.
|
||||
The comparison `\-0.0 < 0.0' is false,
|
||||
but `signbit (\-0.0)' will return a non-zero value.
|
||||
The comparison
|
||||
.IR "-0.0 < 0.0"
|
||||
is false, but
|
||||
.IR "signbit(\-0.0)"
|
||||
will return a non-zero value.
|
||||
.SH "CONFORMING TO"
|
||||
C99.
|
||||
This function is defined in IEC 559 (and the appendix with
|
||||
|
|
Loading…
Reference in New Issue