about summary refs log tree commit diff
path: root/compiler/rustc_llvm/llvm-wrapper/PassWrapper.cpp
diff options
context:
space:
mode:
authorZalathar <Zalathar@users.noreply.github.com>2024-11-03 18:23:59 +1100
committerZalathar <Zalathar@users.noreply.github.com>2024-11-08 22:31:32 +1100
commit730626dbd924d7fbf3873bcf1da783f486efd1d7 (patch)
tree25cfebe89ed1baa22a4bc1a71de8a87c742b2b22 /compiler/rustc_llvm/llvm-wrapper/PassWrapper.cpp
parent6295686a37ed731f1059b07157170c9ac56bf8c3 (diff)
downloadrust-730626dbd924d7fbf3873bcf1da783f486efd1d7.tar.gz
rust-730626dbd924d7fbf3873bcf1da783f486efd1d7.zip
Don't use `LLVMRustStringWriteImpl` outside of `RawRustStringOstream`
Diffstat (limited to 'compiler/rustc_llvm/llvm-wrapper/PassWrapper.cpp')
-rw-r--r--compiler/rustc_llvm/llvm-wrapper/PassWrapper.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/compiler/rustc_llvm/llvm-wrapper/PassWrapper.cpp b/compiler/rustc_llvm/llvm-wrapper/PassWrapper.cpp
index eb99d560e57..6f47ee88add 100644
--- a/compiler/rustc_llvm/llvm-wrapper/PassWrapper.cpp
+++ b/compiler/rustc_llvm/llvm-wrapper/PassWrapper.cpp
@@ -1624,5 +1624,6 @@ extern "C" void LLVMRustComputeLTOCacheKey(RustStringRef KeyOut,
                            CfiFunctionDefs, CfiFunctionDecls);
 #endif
 
-  LLVMRustStringWriteImpl(KeyOut, Key.c_str(), Key.size());
+  auto OS = RawRustStringOstream(KeyOut);
+  OS << Key.str();
 }