diff options
| author | bors <bors@rust-lang.org> | 2023-07-30 19:53:37 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2023-07-30 19:53:37 +0000 |
| commit | a17c7968b727d8413801961fc4e89869b6ab00d3 (patch) | |
| tree | 8bee38ea826aee2c0093d9fb17c315efc9300291 /compiler/rustc_codegen_llvm/src/back/write.rs | |
| parent | a8be6e070f02fca6e5ab851e10e29d45c3a0217c (diff) | |
| parent | 4916ab5330de7a1d762626c1d759321728b00874 (diff) | |
| download | rust-a17c7968b727d8413801961fc4e89869b6ab00d3.tar.gz rust-a17c7968b727d8413801961fc4e89869b6ab00d3.zip | |
Auto merge of #114264 - matthiaskrgr:rollup-dfsuu1v, r=matthiaskrgr
Rollup of 6 pull requests Successful merges: - #98154 (merge functionality of `io::Sink` into `io::Empty`) - #102198 (`const`-stablilize `NonNull::as_ref`) - #114074 (inline format!() args from rustc_middle up to and including rustc_codegen_llvm (3)) - #114246 (Weaken unnameable_types lint) - #114256 (Fix invalid suggestion for mismatched types in closure arguments) - #114258 (Simplify `Span::can_be_used_for_suggestions` a little tiny bit) r? `@ghost` `@rustbot` modify labels: rollup
Diffstat (limited to 'compiler/rustc_codegen_llvm/src/back/write.rs')
| -rw-r--r-- | compiler/rustc_codegen_llvm/src/back/write.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/compiler/rustc_codegen_llvm/src/back/write.rs b/compiler/rustc_codegen_llvm/src/back/write.rs index 0f5e975445f..cbcbdea84da 100644 --- a/compiler/rustc_codegen_llvm/src/back/write.rs +++ b/compiler/rustc_codegen_llvm/src/back/write.rs @@ -259,7 +259,7 @@ pub(crate) fn save_temp_bitcode( return; } unsafe { - let ext = format!("{}.bc", name); + let ext = format!("{name}.bc"); let cgu = Some(&module.name[..]); let path = cgcx.output_filenames.temp_path_ext(&ext, cgu); let cstr = path_to_c_string(&path); @@ -713,7 +713,7 @@ pub(crate) unsafe fn codegen( let Ok(demangled) = rustc_demangle::try_demangle(input) else { return 0 }; - if write!(cursor, "{:#}", demangled).is_err() { + if write!(cursor, "{demangled:#}").is_err() { // Possible only if provided buffer is not big enough return 0; } @@ -834,7 +834,7 @@ pub(crate) unsafe fn codegen( } fn create_section_with_flags_asm(section_name: &str, section_flags: &str, data: &[u8]) -> Vec<u8> { - let mut asm = format!(".section {},\"{}\"\n", section_name, section_flags).into_bytes(); + let mut asm = format!(".section {section_name},\"{section_flags}\"\n").into_bytes(); asm.extend_from_slice(b".ascii \""); asm.reserve(data.len()); for &byte in data { |
