diff options
| author | bors <bors@rust-lang.org> | 2024-07-26 17:21:30 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2024-07-26 17:21:30 +0000 |
| commit | 479491ebce7e30d3096afc9745febb0affff62f7 (patch) | |
| tree | 00f8b21552a4fecf3643f226d193e5f0baf2ff73 /compiler/rustc_llvm/llvm-wrapper/RustWrapper.cpp | |
| parent | 3504145753f9257e01f502dd3b3872dfc6719d2c (diff) | |
| parent | 266abf3c08203d0ae7bf6d0ba18db5a6df2fd1c2 (diff) | |
| download | rust-479491ebce7e30d3096afc9745febb0affff62f7.tar.gz rust-479491ebce7e30d3096afc9745febb0affff62f7.zip | |
Auto merge of #13130 - nyurik:ref-lints, r=Centri3
Avoid ref when using format!
Clean up a few minor refs in `format!` macro, as it has a performance cost. Apparently the compiler is unable to inline `format!("{}", &variable)`, and does a run-time double-reference instead (format macro already does one level referencing).
Inlining format args prevents accidental `&` misuse.
See also https://github.com/rust-lang/rust/issues/112156
changelog: none
Diffstat (limited to 'compiler/rustc_llvm/llvm-wrapper/RustWrapper.cpp')
0 files changed, 0 insertions, 0 deletions
