Fix UB in test helpers

Macro expansion producing defined has undefined behavior in C/C++.
This commit is contained in:
Simonas Kazlauskas 2017-01-16 11:46:00 +02:00
parent 3dcb288420
commit 5add9b93d4

View File

@ -269,10 +269,7 @@ LARGE_INTEGER increment_all_parts(LARGE_INTEGER li) {
return li;
}
#define DO_INT128_TEST !(defined(WIN32) || defined(_WIN32) || defined(__WIN32)) && \
defined(__amd64__)
#if DO_INT128_TEST
#if !(defined(WIN32) || defined(_WIN32) || defined(__WIN32)) && defined(__amd64__)
unsigned __int128 identity(unsigned __int128 a) {
return a;