diff options
| author | Dylan DPC <dylan.dpc@gmail.com> | 2020-02-29 02:16:24 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2020-02-29 02:16:24 +0100 |
| commit | bbfec7ca41887af04abb4510677c4539a95f03a2 (patch) | |
| tree | beca90f2df096a812f1015ada4f9d9638cd73849 /src/librustc | |
| parent | 1bb6760968b92acee0a1f9f7d84fa10805157b59 (diff) | |
| parent | 85e59b7664734b3fb0122aa8d341ed7e878569c1 (diff) | |
Rollup merge of #69567 - matthiaskrgr:useless_fmt, r=nagisa
use .to_string() instead of format!() macro to create strings handles what is left after https://github.com/rust-lang/rust/pull/69541
Diffstat (limited to 'src/librustc')
| -rw-r--r-- | src/librustc/query/mod.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/librustc/query/mod.rs b/src/librustc/query/mod.rs index 69698eabac4..f3249f5014d 100644 --- a/src/librustc/query/mod.rs +++ b/src/librustc/query/mod.rs @@ -18,7 +18,7 @@ use std::borrow::Cow; fn describe_as_module(def_id: DefId, tcx: TyCtxt<'_>) -> String { if def_id.is_top_level_module() { - format!("top-level module") + "top-level module".to_string() } else { format!("module `{}`", tcx.def_path_str(def_id)) } |
