From e3c098246d19704e6df6358357e0eb066ea8f431 Mon Sep 17 00:00:00 2001 From: ado Date: Tue, 23 Feb 2021 02:25:24 +0100 Subject: [PATCH] make clang mingw32 not use builtin overflow functions --- include/ss/extract.hpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/include/ss/extract.hpp b/include/ss/extract.hpp index ebf7ef8..0644e10 100644 --- a/include/ss/extract.hpp +++ b/include/ss/extract.hpp @@ -35,7 +35,9 @@ inline std::optional from_char(char c) { return std::nullopt; } -#if defined(__clang__) || defined(__GNUC__) || defined(__GUNG__) +// mingw32 clang does not support some of the builtin functions +#if (defined(__clang__) && (!defined(__MINGW32__) || defined(__MINGW64__))) || \ + defined(__GNUC__) || defined(__GUNG__) //////////////// // mul overflow detection ////////////////