Skip to content

Commit 8c0a8f5

Browse files
Remove unneeded to_string call
1 parent bb5c437 commit 8c0a8f5

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/librustdoc/html/render/print_item.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -465,7 +465,7 @@ fn extra_info_tags(item: &clean::Item, parent: &clean::Item, tcx: TyCtxt<'_>) ->
465465
fn item_function(w: &mut Buffer, cx: &Context<'_>, it: &clean::Item, f: &clean::Function) {
466466
let header = it.fn_header(cx.tcx()).expect("printing a function which isn't a function");
467467
let constness = print_constness_with_space(&header.constness, it.const_stability(cx.tcx()));
468-
let unsafety = header.unsafety.print_with_space().to_string();
468+
let unsafety = header.unsafety.print_with_space();
469469
let abi = print_abi_with_space(header.abi).to_string();
470470
let asyncness = header.asyncness.print_with_space();
471471
let visibility = it.visibility.print_with_space(it.def_id, cx).to_string();

0 commit comments

Comments
 (0)