summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Analysis/Analysis.cpp
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2010-01-09 22:27:07 +0000
committerChris Lattner <sabre@nondot.org>2010-01-09 22:27:07 +0000
commit25963c6113ea82b568b7c1f48b24ad7c89a24279 (patch)
tree8646d1e025fab5f3379844083540d879d16bcb5e /llvm/lib/Analysis/Analysis.cpp
parente23003d1f1276f24dca2ec064f6cda0a64dec642 (diff)
downloadbcm5719-llvm-25963c6113ea82b568b7c1f48b24ad7c89a24279.tar.gz
bcm5719-llvm-25963c6113ea82b568b7c1f48b24ad7c89a24279.zip
"In order to ease automatic bindings generation, it would be helpful if boolean values were distinguishable from integers. The attached patch introduces "typedef int LLVMBool;", and uses LLVMBool instead of int throughout the C API, wherever a boolean value is called for."
Patch by James Y Knight! llvm-svn: 93079
Diffstat (limited to 'llvm/lib/Analysis/Analysis.cpp')
-rw-r--r--llvm/lib/Analysis/Analysis.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/llvm/lib/Analysis/Analysis.cpp b/llvm/lib/Analysis/Analysis.cpp
index f8cb32321b0..398dec7dd0a 100644
--- a/llvm/lib/Analysis/Analysis.cpp
+++ b/llvm/lib/Analysis/Analysis.cpp
@@ -13,11 +13,11 @@
using namespace llvm;
-int LLVMVerifyModule(LLVMModuleRef M, LLVMVerifierFailureAction Action,
- char **OutMessages) {
+LLVMBool LLVMVerifyModule(LLVMModuleRef M, LLVMVerifierFailureAction Action,
+ char **OutMessages) {
std::string Messages;
- int Result = verifyModule(*unwrap(M),
+ LLVMBool Result = verifyModule(*unwrap(M),
static_cast<VerifierFailureAction>(Action),
OutMessages? &Messages : 0);
@@ -27,7 +27,7 @@ int LLVMVerifyModule(LLVMModuleRef M, LLVMVerifierFailureAction Action,
return Result;
}
-int LLVMVerifyFunction(LLVMValueRef Fn, LLVMVerifierFailureAction Action) {
+LLVMBool LLVMVerifyFunction(LLVMValueRef Fn, LLVMVerifierFailureAction Action) {
return verifyFunction(*unwrap<Function>(Fn),
static_cast<VerifierFailureAction>(Action));
}
OpenPOWER on IntegriCloud