From 2f4680d14308e02bd52abbb81b6c9ae68febe818 Mon Sep 17 00:00:00 2001 From: Johannes Grunenberg Date: Thu, 5 Sep 2024 23:45:37 +0200 Subject: [PATCH] Disable q(u)int128 for Clang with MSVC's STL Clang supports q(u)int128, however, MSVC's STL doesn't have support for it in and . MSVC's STL is used by Clangd on Windows. Fixes: QTBUG-128675 Change-Id: Ic0be6b9d2659477829c7b369385ef885dee8d355 Reviewed-by: Thiago Macieira (cherry picked from commit 1f9a660eb2d5c6e3cb9c80dc292f3ec355296515) Reviewed-by: Qt Cherry-pick Bot --- src/corelib/global/qtypes.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/corelib/global/qtypes.h b/src/corelib/global/qtypes.h index 65bf01fac14..82de5176c1b 100644 --- a/src/corelib/global/qtypes.h +++ b/src/corelib/global/qtypes.h @@ -72,6 +72,9 @@ typedef quint64 qulonglong; # if defined(__GLIBCXX__) && defined(__STRICT_ANSI__) // -ansi/-std=c++NN instead of gnu++NN # undef QT_SUPPORTS_INT128 // breaks on libstdc++ # endif +# if defined(__clang__) && defined(_MSVC_STL_VERSION) // Clang with MSVC's STL +# undef QT_SUPPORTS_INT128 // MSVC's STL doesn't support int128 +# endif #else # undef QT_SUPPORTS_INT128 #endif