Open
Description
Observed non-standard behavior when testing tgamma().
Currently, the tgamma()
function implementation has an inconsistency with error handling.
Errors are reported as specified in math_errhandling.
For IEEE-compatible type double, overflow happens if 0 < x < 1/[DBL_MAX] or if x > 171.7.
If a range error due to overflow occurs, [±HUGE_VAL], ±HUGE_VALF, or ±HUGE_VALL is returned.
POSIX requires that a pole error occurs if the argument is zero, but a domain error occurs when the argument is a negative integer
Specifically, it fails to set errno
to either ERANGE
(for overflow cases) or EDOM
(when the input parameter is a negative integer), as required by standard.
Metadata
Metadata
Assignees
Labels
No labels