diff options
| author | Nicholas Nethercote <n.nethercote@gmail.com> | 2023-11-06 13:06:40 +1100 |
|---|---|---|
| committer | Nicholas Nethercote <n.nethercote@gmail.com> | 2023-11-08 08:57:57 +1100 |
| commit | 1b3733e5a4b625a8b4aa78ed31e90c756b0bc048 (patch) | |
| tree | ae226f08516ef737217479259e9bc4091a756ee2 /compiler/rustc_errors/src | |
| parent | 9bd71afb90c2a6e0348cdd4a2b10a3bf39908f19 (diff) | |
| download | rust-1b3733e5a4b625a8b4aa78ed31e90c756b0bc048.tar.gz rust-1b3733e5a4b625a8b4aa78ed31e90c756b0bc048.zip | |
rustc: minor changes suggested by clippy perf lints.
Diffstat (limited to 'compiler/rustc_errors/src')
| -rw-r--r-- | compiler/rustc_errors/src/emitter.rs | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/compiler/rustc_errors/src/emitter.rs b/compiler/rustc_errors/src/emitter.rs index 6d95fbcfad0..68dba860291 100644 --- a/compiler/rustc_errors/src/emitter.rs +++ b/compiler/rustc_errors/src/emitter.rs @@ -2362,11 +2362,7 @@ impl FileWithAnnotatedLines { let label = label.as_ref().map(|m| { normalize_whitespace( - &emitter - .translate_message(m, &args) - .map_err(Report::new) - .unwrap() - .to_string(), + &emitter.translate_message(m, &args).map_err(Report::new).unwrap(), ) }); |
