16 Library introduction [library]

16.2 The C standard library [library.c]

The C++ standard library also makes available the facilities of the C standard library, suitably adjusted to ensure static type safety.
The descriptions of many library functions rely on the C standard library for the semantics of those functions.
In some cases, the signatures specified in this document may be different from the signatures in the C standard library, and additional overloads may be declared in this document, but the behavior and the preconditions (including any preconditions implied by the use of an ISO C restrict qualifier) are the same unless otherwise stated.
A call to a C standard library function is a non-constant library call ([defns.nonconst.libcall]) if it raises a floating-point exception other than FE_­INEXACT.
The semantics of a call to a C standard library function evaluated as a core constant expression are those specified in Annex F of the C standard142 to the extent applicable to the floating-point types ([basic.fundamental]) that are parameter types of the called function.
[Note 1:
Annex F specifies the conditions under which floating-point exceptions are raised and the behavior when NaNs and/or infinities are passed as arguments.
— end note]
[Note 2:
Equivalently, a call to a C standard library function is a non-constant library call if errno is set when math_­errhandling & MATH_­ERRNO is true.
— end note]
142)142)
See also ISO/IEC 9899:2018 section 7.6.