Thanks,
to add a little bit more
#include <math.h>
int main() {
long double r, fa = 4, fb = 6;
long a = 4, b = 6;
int aa = 4, bb = 6;
r = atan2l(fa, fb);
printf("%.20Lf\n", r);
r = atan2l(aa, bb);
printf("%.20Lf\n", r);
r = atan2l(a, b);
printf("%.20Lf\n", r);
r = atan2(4, 6);
printf("%.20Lf\n", r);
r = atan2l(4, 6);
printf("%.20Lf\n", r);
r = atan2l(4LL, 6LL);
printf("%.20Lf\n", r);
r = atan2l(4., 6.);
printf("%.20Lf\n", r);
}
produces
0.58800260354756750392
0.58800260354756750392
0.58800260354756750392
0.58800260354756750392
0.58800260354756755124
0.58800260354756755124
0.58800260354756755124
with gcc on NetBSD.
clang always prints the same.
Funny thing is when arguments are passed as literals,
no precission loss. For variables, precision is degraded
for any variabe type, even for long double.