[llvm-commits] [llvm] r143468 - /llvm/trunk/include/llvm/Support/Compiler.h

Daniel Dunbar daniel at zuster.org
Tue Nov 1 10:46:12 PDT 2011


Author: ddunbar
Date: Tue Nov  1 12:46:12 2011
New Revision: 143468

URL: http://llvm.org/viewvc/llvm-project?rev=143468&view=rev
Log:
Support/Compiler: Add LLVM_EXTENSION for use where we want to hide pedantic diags.

Modified:
    llvm/trunk/include/llvm/Support/Compiler.h

Modified: llvm/trunk/include/llvm/Support/Compiler.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/Support/Compiler.h?rev=143468&r1=143467&r2=143468&view=diff
==============================================================================
--- llvm/trunk/include/llvm/Support/Compiler.h (original)
+++ llvm/trunk/include/llvm/Support/Compiler.h Tue Nov  1 12:46:12 2011
@@ -111,6 +111,14 @@
 #define LLVM_ATTRIBUTE_NORETURN
 #endif
 
+// LLVM_EXTENSION - Support compilers where we have a keyword to suppress
+// pedantic diagnostics.
+#ifdef __GNUC__
+#define LLVM_EXTENSION __extension__
+#else
+#define LLVM_EXTENSION
+#endif
+
 // LLVM_ATTRIBUTE_DEPRECATED(decl, "message")
 #if __has_feature(attribute_deprecated_with_message)
 # define LLVM_ATTRIBUTE_DEPRECATED(decl, message) \





More information about the llvm-commits mailing list