Replace LLVMRustContextCreate with normal LLVM-C API calls
Since `LLVMRustContextCreate` can easily be replaced with a call to `LLVMContextCreate` and `LLVMContextSetDiscardValueNames`.
This commit is contained in:
parent
9725c4baac
commit
0abecda9ed
3 changed files with 10 additions and 12 deletions
|
|
@ -123,12 +123,6 @@ extern "C" void LLVMRustSetLastError(const char *Err) {
|
|||
LastError = strdup(Err);
|
||||
}
|
||||
|
||||
extern "C" LLVMContextRef LLVMRustContextCreate(bool shouldDiscardNames) {
|
||||
auto ctx = new LLVMContext();
|
||||
ctx->setDiscardValueNames(shouldDiscardNames);
|
||||
return wrap(ctx);
|
||||
}
|
||||
|
||||
extern "C" void LLVMRustSetNormalizedTarget(LLVMModuleRef M,
|
||||
const char *Target) {
|
||||
#if LLVM_VERSION_GE(21, 0)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue