Issue36330
Created on 2019-03-17 19:20 by matrixise, last changed 2022-04-11 14:59 by admin.
| Messages (4) | |||
|---|---|---|---|
| msg338137 - (view) | Author: Stéphane Wirtel (matrixise) * ![]() |
Date: 2019-03-17 19:20 | |
env CC="/usr/bin/clang" CCX="/usr/bin/clang" ./configure > /dev/null ;and make -j 4 > /dev/null
./Modules/timemodule.c:113:13: warning: code will never be executed [-Wunreachable-code]
PyErr_SetString(PyExc_OverflowError,
^~~~~~~~~~~~~~~
1 warning generated.
|
|||
| msg338138 - (view) | Author: Paul Ganssle (p-ganssle) * ![]() |
Date: 2019-03-17 19:55 | |
It does seem like the values CLOCKS_PER_SEC, _PyTime_MAX and SEC_TO_NS are all defined at compile-time, so presumably this can be a compile-time error. As currently defined, though, it seems very unlikely that this would ever be false, since _PyTime_MAX is the same as LLONG_MAX, which cplusplusreference says is `9223372036854775807 (2**63-1) or greater` [0], so CLOCKS_PER_SEC would need to be >= 2**50, which is unlikely to be... accurate. In any case, it seems like this check can happen at compile-time, either resulting in compilation failing, or just undefining HAVE_CLOCK. [0] http://www.cplusplus.com/reference/climits/ |
|||
| msg338139 - (view) | Author: Paul Ganssle (p-ganssle) * ![]() |
Date: 2019-03-17 19:58 | |
Sorry, I should say unlikely that it should ever be *true*. It seems unlikely that there is a platform or piece of hardware on which this error would be raised. |
|||
| msg338144 - (view) | Author: Stéphane Wirtel (matrixise) * ![]() |
Date: 2019-03-17 22:29 | |
Hi Paul, Thank you for your explanation, I was not sure about the solution and I have just preferred to publish this issue. I don't have this issue with gcc, only with clang. |
|||
| History | |||
|---|---|---|---|
| Date | User | Action | Args |
| 2022-04-11 14:59:12 | admin | set | github: 80511 |
| 2019-03-17 22:29:54 | matrixise | set | messages: + msg338144 |
| 2019-03-17 19:58:24 | p-ganssle | set | messages: + msg338139 |
| 2019-03-17 19:55:56 | p-ganssle | set | nosy:
+ p-ganssle messages: + msg338138 |
| 2019-03-17 19:20:11 | matrixise | create | |
