mirror of
https://github.com/rust-lang/rust.git
synced 2026-04-27 18:57:42 +03:00
setTargetTriple now accepts Triple rather than string
This commit is contained in:
@@ -153,7 +153,11 @@ extern "C" LLVMContextRef LLVMRustContextCreate(bool shouldDiscardNames) {
|
||||
|
||||
extern "C" void LLVMRustSetNormalizedTarget(LLVMModuleRef M,
|
||||
const char *Triple) {
|
||||
#if LLVM_VERSION_GE(21, 0)
|
||||
unwrap(M)->setTargetTriple(llvm::Triple(Triple::normalize(Triple)));
|
||||
#else
|
||||
unwrap(M)->setTargetTriple(Triple::normalize(Triple));
|
||||
#endif
|
||||
}
|
||||
|
||||
extern "C" void LLVMRustPrintPassTimings(RustStringRef OutBuf) {
|
||||
|
||||
Reference in New Issue
Block a user