diff options
author | Chris Lattner <sabre@nondot.org> | 2010-01-09 22:27:07 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2010-01-09 22:27:07 +0000 |
commit | d686c8e73f74e37ab5f647b65a12051ee6cbad16 (patch) | |
tree | 06a78b36c6cc4de9d05158641373fb4e1bde72a0 /lib/VMCore/PassManager.cpp | |
parent | 95fa80af6f0451bb52cd2d86dea1b165c5e2675a (diff) |
"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!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@93079 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/VMCore/PassManager.cpp')
-rw-r--r-- | lib/VMCore/PassManager.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/VMCore/PassManager.cpp b/lib/VMCore/PassManager.cpp index 1d461c3d4b..b37b2aeda8 100644 --- a/lib/VMCore/PassManager.cpp +++ b/lib/VMCore/PassManager.cpp @@ -1699,19 +1699,19 @@ LLVMPassManagerRef LLVMCreateFunctionPassManager(LLVMModuleProviderRef P) { return wrap(new FunctionPassManager(unwrap(P))); } -int LLVMRunPassManager(LLVMPassManagerRef PM, LLVMModuleRef M) { +LLVMBool LLVMRunPassManager(LLVMPassManagerRef PM, LLVMModuleRef M) { return unwrap<PassManager>(PM)->run(*unwrap(M)); } -int LLVMInitializeFunctionPassManager(LLVMPassManagerRef FPM) { +LLVMBool LLVMInitializeFunctionPassManager(LLVMPassManagerRef FPM) { return unwrap<FunctionPassManager>(FPM)->doInitialization(); } -int LLVMRunFunctionPassManager(LLVMPassManagerRef FPM, LLVMValueRef F) { +LLVMBool LLVMRunFunctionPassManager(LLVMPassManagerRef FPM, LLVMValueRef F) { return unwrap<FunctionPassManager>(FPM)->run(*unwrap<Function>(F)); } -int LLVMFinalizeFunctionPassManager(LLVMPassManagerRef FPM) { +LLVMBool LLVMFinalizeFunctionPassManager(LLVMPassManagerRef FPM) { return unwrap<FunctionPassManager>(FPM)->doFinalization(); } |