about summary refs log tree commit diff
path: root/tests/codegen/patchable-function-entry/patchable-function-entry-no-flag.rs
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2024-07-20 06:40:27 +0000
committerbors <bors@rust-lang.org>2024-07-20 06:40:27 +0000
commitaa52c5d9639ec7bff59576b4e9b466ca215eaed7 (patch)
treea6ca7149a045d5e864e59750fabc5dd32116df18 /tests/codegen/patchable-function-entry/patchable-function-entry-no-flag.rs
parent91b9739d124e75d410971e94b628bf6b4f359b0c (diff)
parentafa72d53e3e68cdf7beeae662fce6f28e84e4e3d (diff)
downloadrust-aa52c5d9639ec7bff59576b4e9b466ca215eaed7.tar.gz
rust-aa52c5d9639ec7bff59576b4e9b466ca215eaed7.zip
Auto merge of #17641 - nyurik:optimize-refs, r=Veykril
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 https://github.com/rust-lang/rust-clippy/issues/10851
Diffstat (limited to 'tests/codegen/patchable-function-entry/patchable-function-entry-no-flag.rs')
0 files changed, 0 insertions, 0 deletions