summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--include/llvm-c/Core.h11
-rw-r--r--include/llvm-c/Support.h21
-rw-r--r--include/llvm/Support/MemoryBuffer.h2
3 files changed, 22 insertions, 12 deletions
diff --git a/include/llvm-c/Core.h b/include/llvm-c/Core.h
index 437023bfba..bd150eaaae 100644
--- a/include/llvm-c/Core.h
+++ b/include/llvm-c/Core.h
@@ -15,7 +15,7 @@
#ifndef LLVM_C_CORE_H
#define LLVM_C_CORE_H
-#include "llvm/Support/DataTypes.h"
+#include "llvm-c/Support.h"
#ifdef __cplusplus
extern "C" {
@@ -62,8 +62,6 @@ extern "C" {
* @{
*/
-typedef int LLVMBool;
-
/* Opaque types. */
/**
@@ -114,13 +112,6 @@ typedef struct LLVMOpaqueBuilder *LLVMBuilderRef;
*/
typedef struct LLVMOpaqueModuleProvider *LLVMModuleProviderRef;
-/**
- * Used to provide a module to JIT or interpreter.
- *
- * @see llvm::MemoryBuffer
- */
-typedef struct LLVMOpaqueMemoryBuffer *LLVMMemoryBufferRef;
-
/** @see llvm::PassManagerBase */
typedef struct LLVMOpaquePassManager *LLVMPassManagerRef;
diff --git a/include/llvm-c/Support.h b/include/llvm-c/Support.h
index 7f03ede604..4e6ff220b1 100644
--- a/include/llvm-c/Support.h
+++ b/include/llvm-c/Support.h
@@ -14,13 +14,32 @@
#ifndef LLVM_C_SUPPORT_H
#define LLVM_C_SUPPORT_H
-#include "llvm-c/Core.h"
+#include "llvm/Support/DataTypes.h"
#ifdef __cplusplus
extern "C" {
#endif
/**
+ * @defgroup LLVMCSupportTypes Types and Enumerations
+ *
+ * @{
+ */
+
+typedef int LLVMBool;
+
+/**
+ * Used to pass regions of memory through LLVM interfaces.
+ *
+ * @see llvm::MemoryBuffer
+ */
+typedef struct LLVMOpaqueMemoryBuffer *LLVMMemoryBufferRef;
+
+/**
+ * @}
+ */
+
+/**
* This function permanently loads the dynamic library at the given path.
* It is safe to call this function multiple times for the same library.
*
diff --git a/include/llvm/Support/MemoryBuffer.h b/include/llvm/Support/MemoryBuffer.h
index 1910d44240..578c7e8eb8 100644
--- a/include/llvm/Support/MemoryBuffer.h
+++ b/include/llvm/Support/MemoryBuffer.h
@@ -14,7 +14,7 @@
#ifndef LLVM_SUPPORT_MEMORYBUFFER_H
#define LLVM_SUPPORT_MEMORYBUFFER_H
-#include "llvm-c/Core.h"
+#include "llvm-c/Support.h"
#include "llvm/ADT/Twine.h"
#include "llvm/Support/CBindingWrapping.h"
#include "llvm/Support/Compiler.h"