JosiahWI commented on code in PR #10680:
URL: https://github.com/apache/trafficserver/pull/10680#discussion_r1373720952
##########
cmake/Check128BitCas.cmake:
##########
@@ -25,18 +25,16 @@
set(CHECK_PROGRAM
"
- int
- main()
+ int main(void)
{
__int128_t x = 0;
- __sync_bool_compare_and_swap(&x,0,10);
-
- return 0;
+ return __sync_bool_compare_and_swap(&x,0,10);
Review Comment:
I think the main issue isn't whether it returns a `bool` but whether the
return value is correct. `__sync_bool_compare_and_swap` will return a truthy
value if it succeeds, which will indicate an exit failure if main returns it.
That shouldn't interfere with CMake's check, but it seems risky.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]