If any argument value
to any of the functions specified in [sf.cmath]
is a NaN (Not a Number),
the function shall return a NaN
but it shall not report a domain error.
Otherwise,
the function shall report a domain error
for just those argument values
for which:
A mathematical function
is mathematically defined
for a given set of argument values
(a)
if it is explicitly defined
for that set of argument values,
or
(b)
if its limiting value exists
and does not depend
on the direction of approach.