[libcxx] r293439 - config: prevent the re-definition of a macro
Saleem Abdulrasool via cfe-commits
cfe-commits at lists.llvm.org
Sun Jan 29 10:16:33 PST 2017
Author: compnerd
Date: Sun Jan 29 12:16:33 2017
New Revision: 293439
URL: http://llvm.org/viewvc/llvm-project?rev=293439&view=rev
Log:
config: prevent the re-definition of a macro
This causes unnecessary warnings when building with `cl`. Newer
versions of the C standard permit the redefinition of the macro to the
same value (which is the case here), unfortunately, `cl` does not yet
implement this. Add a check to prevent the redefinition.
Modified:
libcxx/trunk/include/__config
Modified: libcxx/trunk/include/__config
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/include/__config?rev=293439&r1=293438&r2=293439&view=diff
==============================================================================
--- libcxx/trunk/include/__config (original)
+++ libcxx/trunk/include/__config Sun Jan 29 12:16:33 2017
@@ -12,8 +12,10 @@
#define _LIBCPP_CONFIG
#if defined(_MSC_VER) && !defined(__clang__)
+#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#define _LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER
#endif
+#endif
#ifndef _LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER
#pragma GCC system_header
More information about the cfe-commits
mailing list