diff options
| author | Matthias Krüger <matthias.krueger@famsik.de> | 2024-07-20 07:13:45 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-07-20 07:13:45 +0200 |
| commit | cd8c5f78ec8140a8902747689c9d4b8080d7c66d (patch) | |
| tree | 0ef9a4eb81485a2bdb06e66cbe7693b23cead2da /compiler/rustc_interface/src/errors.rs | |
| parent | 767b3cb54bb31a9f6d1ba52605f63528c493276d (diff) | |
| parent | aef0e346de744faeaa522b9c08562bb3e1814adc (diff) | |
| download | rust-cd8c5f78ec8140a8902747689c9d4b8080d7c66d.tar.gz rust-cd8c5f78ec8140a8902747689c9d4b8080d7c66d.zip | |
Rollup merge of #127980 - nyurik:compiler-refs, r=oli-obk
Avoid ref when using format! in compiler
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-clippy/issues/10851
Diffstat (limited to 'compiler/rustc_interface/src/errors.rs')
0 files changed, 0 insertions, 0 deletions
