r210487 - Disallow multiple inclusion of clang/Config/config.h
Alp Toker
alp at nuanti.com
Mon Jun 9 12:09:28 PDT 2014
Author: alp
Date: Mon Jun 9 14:09:28 2014
New Revision: 210487
URL: http://llvm.org/viewvc/llvm-project?rev=210487&view=rev
Log:
Disallow multiple inclusion of clang/Config/config.h
Internal config.h headers are only meant to be included from the main file.
Modified:
cfe/trunk/include/clang/Config/config.h.cmake
cfe/trunk/include/clang/Config/config.h.in
Modified: cfe/trunk/include/clang/Config/config.h.cmake
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/Config/config.h.cmake?rev=210487&r1=210486&r2=210487&view=diff
==============================================================================
--- cfe/trunk/include/clang/Config/config.h.cmake (original)
+++ cfe/trunk/include/clang/Config/config.h.cmake Mon Jun 9 14:09:28 2014
@@ -1,4 +1,8 @@
-#ifndef CONFIG_H
+/* This generated file is for internal use. Do not include it from headers. */
+
+#ifdef CONFIG_H
+#error config.h can only be included once
+#else
#define CONFIG_H
/* Bug report URL. */
Modified: cfe/trunk/include/clang/Config/config.h.in
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/Config/config.h.in?rev=210487&r1=210486&r2=210487&view=diff
==============================================================================
--- cfe/trunk/include/clang/Config/config.h.in (original)
+++ cfe/trunk/include/clang/Config/config.h.in Mon Jun 9 14:09:28 2014
@@ -1,4 +1,8 @@
-#ifndef CONFIG_H
+/* This generated file is for internal use. Do not include it from headers. */
+
+#ifdef CONFIG_H
+#error config.h can only be included once
+#else
#define CONFIG_H
/* Bug report URL. */
More information about the cfe-commits
mailing list