diff options
-rw-r--r-- | include/o3tl/safeint.hxx | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/include/o3tl/safeint.hxx b/include/o3tl/safeint.hxx index 56175edb3bbe..67af99cf810c 100644 --- a/include/o3tl/safeint.hxx +++ b/include/o3tl/safeint.hxx @@ -82,7 +82,8 @@ template<typename T> inline bool checked_sub(T a, T b, T& result) return !msl::utilities::SafeSubtract(a, b, result); } -#elif (defined __GNUC__ && __GNUC__ >= 5) || (__has_builtin(__builtin_mul_overflow) && !(defined ANDROID && defined __clang__)) +#elif (defined __GNUC__ && __GNUC__ >= 5) || (__has_builtin(__builtin_mul_overflow) && !(defined ANDROID && defined __clang__) && !(defined(__clang__) && defined(__i386__) && __clang_major__ == 4)) +// 32-bit clang 4.0.1 fails with undefined reference to `__mulodi4' template<typename T> inline bool checked_multiply(T a, T b, T& result) { |