Revert r178713
authorEvan Cheng <evan.cheng@apple.com>
Thu, 4 Apr 2013 17:40:53 +0000 (17:40 +0000)
committerEvan Cheng <evan.cheng@apple.com>
Thu, 4 Apr 2013 17:40:53 +0000 (17:40 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@178769 91177308-0d34-0410-b5e6-96231b3b80d8

include/llvm-c/Core.h
include/llvm-c/ExecutionEngine.h
include/llvm-c/Object.h
include/llvm-c/Target.h
include/llvm-c/TargetMachine.h
include/llvm-c/Transforms/PassManagerBuilder.h

index cc78b2e6fd28612e96fc1cf332a3e291344311fd..e85fb9750503472c84f882581dd8c3ef8b908103 100644 (file)
 
 #include "llvm/Support/DataTypes.h"
 
-#if defined(__cplusplus) && !defined(LLVM_DO_NOT_INCLUDE_CPP_HEADERS)
+#ifdef __cplusplus
+
 /* Need these includes to support the LLVM 'cast' template for the C++ 'wrap' 
    and 'unwrap' conversion functions. */
 #include "llvm/IR/IRBuilder.h"
 #include "llvm/IR/Module.h"
 #include "llvm/PassRegistry.h"
-#endif /* defined(__cplusplus) && !defined(LLVM_DO_NOT_INCLUDE_CPP_HEADERS) */
 
-#ifdef __cplusplus
 extern "C" {
 #endif
 
@@ -2670,9 +2669,7 @@ LLVMBool LLVMIsMultithreaded();
 
 #ifdef __cplusplus
 }
-#endif
 
-#if defined(__cplusplus) && !defined(LLVM_DO_NOT_INCLUDE_CPP_HEADERS)
 namespace llvm {
   class MemoryBuffer;
   class PassManagerBase;
@@ -2766,6 +2763,6 @@ namespace llvm {
   }
 }
 
-#endif /* defined(__cplusplus) && !defined(LLVM_DO_NOT_INCLUDE_CPP_HEADERS) */
+#endif /* !defined(__cplusplus) */
 
-#endif /* defined(LLVM_C_CORE_H) */
+#endif /* !defined(LLVM_C_CORE_H) */
index 6ca316c2b1bda344f2a4644ab429a004c15064c7..cb77bb2e2e23d4c68021d02d28f30c14af10d2eb 100644 (file)
@@ -138,9 +138,7 @@ void *LLVMGetPointerToGlobal(LLVMExecutionEngineRef EE, LLVMValueRef Global);
 
 #ifdef __cplusplus
 }
-#endif
 
-#if defined(__cplusplus) && !defined(LLVM_DO_NOT_INCLUDE_CPP_HEADERS)
 namespace llvm {
   struct GenericValue;
   class ExecutionEngine;
@@ -159,6 +157,7 @@ namespace llvm {
   
   #undef DEFINE_SIMPLE_CONVERSION_FUNCTIONS
 }
-#endif /* defined(__cplusplus) && !defined(LLVM_DO_NOT_INCLUDE_CPP_HEADERS) */
+  
+#endif /* defined(__cplusplus) */
 
 #endif
index b6fe17a159f515410e73a07836f19fc0b9572e47..e2dad62b4e07b8f946cdc42545373d472c995f99 100644 (file)
 #include "llvm-c/Core.h"
 #include "llvm/Config/llvm-config.h"
 
-#if defined(__cplusplus) && !defined(LLVM_DO_NOT_INCLUDE_CPP_HEADERS)
+#ifdef __cplusplus
 #include "llvm/Object/ObjectFile.h"
-#endif /* defined(__cplusplus) && !defined(LLVM_DO_NOT_INCLUDE_CPP_HEADERS) */
 
-#ifdef __cplusplus
 extern "C" {
 #endif
 
@@ -101,9 +99,7 @@ const char *LLVMGetRelocationValueString(LLVMRelocationIteratorRef RI);
 
 #ifdef __cplusplus
 }
-#endif
 
-#if defined(__cplusplus) && !defined(LLVM_DO_NOT_INCLUDE_CPP_HEADERS)
 namespace llvm {
   namespace object {
     inline ObjectFile *unwrap(LLVMObjectFileRef OF) {
@@ -146,8 +142,8 @@ namespace llvm {
 
   }
 }
-#endif /* defined(__cplusplus) && !defined(LLVM_DO_NOT_INCLUDE_CPP_HEADERS) */
 
+#endif /* defined(__cplusplus) */
 
 #endif
 
index 0327c04f177a98f4e9163db4d0d665da3e027ab7..57abfa0207fe7f936753a3b76362597c118b450d 100644 (file)
@@ -235,9 +235,7 @@ void LLVMDisposeTargetData(LLVMTargetDataRef);
 
 #ifdef __cplusplus
 }
-#endif
 
-#if defined(__cplusplus) && !defined(LLVM_DO_NOT_INCLUDE_CPP_HEADERS)
 namespace llvm {
   class DataLayout;
   class TargetLibraryInfo;
@@ -259,6 +257,7 @@ namespace llvm {
     return reinterpret_cast<LLVMTargetLibraryInfoRef>(X);
   }
 }
-#endif /* defined(__cplusplus) && !defined(LLVM_DO_NOT_INCLUDE_CPP_HEADERS) */
+
+#endif /* defined(__cplusplus) */
 
 #endif
index e6f477af78786c7c0d5face14ef6f77a941b4372..691abdfcb47acc18a6b73fcbd15c93c29664374f 100644 (file)
@@ -119,9 +119,7 @@ LLVMBool LLVMTargetMachineEmitToFile(LLVMTargetMachineRef T, LLVMModuleRef M,
 
 #ifdef __cplusplus
 }
-#endif
 
-#if defined(__cplusplus) && !defined(LLVM_DO_NOT_INCLUDE_CPP_HEADERS)
 namespace llvm {
   class TargetMachine;
   class Target;
@@ -140,6 +138,6 @@ namespace llvm {
     return reinterpret_cast<LLVMTargetRef>(const_cast<Target*>(P));
   }
 }
-#endif /* defined(__cplusplus) && !defined(LLVM_DO_NOT_INCLUDE_CPP_HEADERS) */
+#endif
 
 #endif
index b39dd243991a0715a9b3d6f650e1876d16c3c826..82e513d4905d9ff19484861703c6b8ee22f8654c 100644 (file)
 
 typedef struct LLVMOpaquePassManagerBuilder *LLVMPassManagerBuilderRef;
 
-#if defined(__cplusplus) && !defined(LLVM_DO_NOT_INCLUDE_CPP_HEADERS)
-#include "llvm/Transforms/IPO/PassManagerBuilder.h"
-#endif
-
 #ifdef __cplusplus
+#include "llvm/Transforms/IPO/PassManagerBuilder.h"
 extern "C" {
 #endif
 
@@ -89,9 +86,7 @@ void LLVMPassManagerBuilderPopulateLTOPassManager(LLVMPassManagerBuilderRef PMB,
 
 #ifdef __cplusplus
 }
-#endif
 
-#if defined(__cplusplus) && !defined(LLVM_DO_NOT_INCLUDE_CPP_HEADERS)
 namespace llvm {
   inline PassManagerBuilder *unwrap(LLVMPassManagerBuilderRef P) {
     return reinterpret_cast<PassManagerBuilder*>(P);
@@ -101,6 +96,6 @@ namespace llvm {
     return reinterpret_cast<LLVMPassManagerBuilderRef>(P);
   }
 }
-#endif /* defined(__cplusplus) && !defined(LLVM_DO_NOT_INCLUDE_CPP_HEADERS) */
+#endif
 
 #endif