diff options
author | Gabor Greif <ggreif@gmail.com> | 2008-04-06 20:25:17 +0000 |
---|---|---|
committer | Gabor Greif <ggreif@gmail.com> | 2008-04-06 20:25:17 +0000 |
commit | d6da1d0d17e2605363504f044664696f4d85b30f (patch) | |
tree | 76db4bc690c153a1cfbd2989849c3b1d95500390 /lib/VMCore/Core.cpp | |
parent | 6af9244457f24a4e9f2165d9f478e3e9cb225777 (diff) | |
download | external_llvm-d6da1d0d17e2605363504f044664696f4d85b30f.zip external_llvm-d6da1d0d17e2605363504f044664696f4d85b30f.tar.gz external_llvm-d6da1d0d17e2605363504f044664696f4d85b30f.tar.bz2 |
API changes for class Use size reduction, wave 1.
Specifically, introduction of XXX::Create methods
for Users that have a potentially variable number of
Uses.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@49277 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/VMCore/Core.cpp')
-rw-r--r-- | lib/VMCore/Core.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/lib/VMCore/Core.cpp b/lib/VMCore/Core.cpp index c35c85d..8c9626a 100644 --- a/lib/VMCore/Core.cpp +++ b/lib/VMCore/Core.cpp @@ -670,8 +670,8 @@ void LLVMSetGlobalConstant(LLVMValueRef GlobalVar, int IsConstant) { LLVMValueRef LLVMAddFunction(LLVMModuleRef M, const char *Name, LLVMTypeRef FunctionTy) { - return wrap(new Function(unwrap<FunctionType>(FunctionTy), - GlobalValue::ExternalLinkage, Name, unwrap(M))); + return wrap(Function::Create(unwrap<FunctionType>(FunctionTy), + GlobalValue::ExternalLinkage, Name, unwrap(M))); } LLVMValueRef LLVMGetNamedFunction(LLVMModuleRef M, const char *Name) { @@ -864,14 +864,14 @@ LLVMBasicBlockRef LLVMGetPreviousBasicBlock(LLVMBasicBlockRef BB) { } LLVMBasicBlockRef LLVMAppendBasicBlock(LLVMValueRef FnRef, const char *Name) { - return wrap(new BasicBlock(Name, unwrap<Function>(FnRef))); + return wrap(BasicBlock::Create(Name, unwrap<Function>(FnRef))); } LLVMBasicBlockRef LLVMInsertBasicBlock(LLVMBasicBlockRef InsertBeforeBBRef, const char *Name) { BasicBlock *InsertBeforeBB = unwrap(InsertBeforeBBRef); - return wrap(new BasicBlock(Name, InsertBeforeBB->getParent(), - InsertBeforeBB)); + return wrap(BasicBlock::Create(Name, InsertBeforeBB->getParent(), + InsertBeforeBB)); } void LLVMDeleteBasicBlock(LLVMBasicBlockRef BBRef) { |