rustllvm: Add a GetOrInsertFunction wrapper
Fixes issue #1161 Test-case-by: Brian Anderson <banderson@mozilla.com> Signed-off-by: Haitao Li <lihaitao@gmail.com>
This commit is contained in:
parent
453168d917
commit
b8dd148444
5 changed files with 23 additions and 1 deletions
|
@ -141,3 +141,9 @@ extern "C" void LLVMRustEnableSegmentedStacks() {
|
|||
EnableSegmentedStacks = true;
|
||||
}
|
||||
|
||||
extern "C" LLVMValueRef LLVMGetOrInsertFunction(LLVMModuleRef M,
|
||||
const char* Name,
|
||||
LLVMTypeRef FunctionTy) {
|
||||
return wrap(unwrap(M)->getOrInsertFunction(Name,
|
||||
unwrap<FunctionType>(FunctionTy)));
|
||||
}
|
||||
|
|
|
@ -364,6 +364,7 @@ LLVMGetNextParam
|
|||
LLVMGetNextUse
|
||||
LLVMGetNumOperands
|
||||
LLVMGetOperand
|
||||
LLVMGetOrInsertFunction
|
||||
LLVMGetParam
|
||||
LLVMGetParamParent
|
||||
LLVMGetParamTypes
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue