diff options
author | H.J. Lu <hjl.tools@gmail.com> | 2024-12-17 05:52:43 +0800 |
---|---|---|
committer | H.J. Lu <hjl.tools@gmail.com> | 2024-12-18 01:26:52 +0800 |
commit | 77e921bc611ea56eba206354c5134af0610cf6fe (patch) | |
tree | 5e22b914312f65fdba6c13c2f7e5e0d3dd969c1e /benchtests/json-lib.c | |
parent | 4666f5c3eebd95e3e39dfb7923aa74c28db4fb8a (diff) | |
download | glibc-77e921bc611ea56eba206354c5134af0610cf6fe.zip glibc-77e921bc611ea56eba206354c5134af0610cf6fe.tar.gz glibc-77e921bc611ea56eba206354c5134af0610cf6fe.tar.bz2 |
tst-timespec.c: Explicitly cast TIME_T_MAX to double
Explicitly cast TIME_T_MAX to double in tst-timespec.c to silence Clang
error:
tst-timespec.c:290:19: error: implicit conversion from 'time_t' (aka 'long') to 'double' changes value from 9223372036854775807 to 9223372036854775808 [-Werror,-Wimplicit-const-int-float-conversion]
287 | {.expected = {.tv_sec = 0, .tv_nsec = 1},
| ~
288 | .observed = {.tv_sec = TIME_T_MAX / TIMESPEC_HZ,
289 | .tv_nsec = TIMESPEC_HZ - 1},
290 | .upper_bound = TIME_T_MAX, .lower_bound = 1, .result = 1,
| ^~~~~~~~~~
Signed-off-by: H.J. Lu <hjl.tools@gmail.com>
Reviewed-by: Sam James <sam@gentoo.org>
Diffstat (limited to 'benchtests/json-lib.c')
0 files changed, 0 insertions, 0 deletions