diff options
Diffstat (limited to 'src/3rdparty/masm/wtf/Assertions.h')
-rw-r--r-- | src/3rdparty/masm/wtf/Assertions.h | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/3rdparty/masm/wtf/Assertions.h b/src/3rdparty/masm/wtf/Assertions.h index be25d43826..d49354311d 100644 --- a/src/3rdparty/masm/wtf/Assertions.h +++ b/src/3rdparty/masm/wtf/Assertions.h @@ -116,7 +116,11 @@ /* WTF logging functions can process %@ in the format string to log a NSObject* but the printf format attribute emits a warning when %@ is used in the format string. Until <rdar://problem/5195437> is resolved we can't include the attribute when being used from Objective-C code in case it decides to use %@. */ -#if COMPILER(GCC) && !defined(__OBJC__) +/* clang requires the attribute before the function (and pretends to be GCC), breaking the common + usage of the macro. Instead of modifying WTF code all over the place, simply disable the attribute + for clang. + */ +#if COMPILER(GCC) && !defined(__OBJC__) && !COMPILER(CLANG) #define WTF_ATTRIBUTE_PRINTF(formatStringArgument, extraArguments) __attribute__((__format__(printf, formatStringArgument, extraArguments))) #else #define WTF_ATTRIBUTE_PRINTF(formatStringArgument, extraArguments) @@ -215,7 +219,7 @@ WTF_EXPORT_PRIVATE void WTFInstallReportBacktraceOnCrashHook(); #if OS(WINCE) /* FIXME: We include this here only to avoid a conflict with the ASSERT macro. */ -#include <windows.h> +#include <qt_windows.h> #undef min #undef max #undef ERROR |