Skip to content

Commit 23bfbe2

Browse files
committed
Fix nightly build
1 parent 9b18ada commit 23bfbe2

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/monomorphize_collector.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -368,7 +368,7 @@ fn collect_items_rec<'tcx>(
368368
/// If the type name is longer than before+after, it will be written to a file.
369369
fn shrunk_instance_name<'tcx>(
370370
tcx: TyCtxt<'tcx>,
371-
instance: &Instance<'tcx>,
371+
instance: Instance<'tcx>,
372372
) -> (String, Option<PathBuf>) {
373373
let s = instance.to_string();
374374

@@ -416,7 +416,7 @@ fn check_recursion_limit<'tcx>(
416416
if !recursion_limit.value_within_limit(adjusted_recursion_depth) {
417417
let def_span = tcx.def_span(def_id);
418418
let def_path_str = tcx.def_path_str(def_id);
419-
let (shrunk, written_to_path) = shrunk_instance_name(tcx, &instance);
419+
let (shrunk, written_to_path) = shrunk_instance_name(tcx, instance);
420420
let error = format!(
421421
"reached the recursion limit while instantiating `{}`",
422422
shrunk
@@ -456,7 +456,7 @@ fn check_type_length_limit<'tcx>(tcx: TyCtxt<'tcx>, instance: Instance<'tcx>) {
456456
//
457457
// Bail out in these cases to avoid that bad user experience.
458458
if !tcx.type_length_limit().value_within_limit(type_length) {
459-
let (shrunk, written_to_path) = shrunk_instance_name(tcx, &instance);
459+
let (shrunk, written_to_path) = shrunk_instance_name(tcx, instance);
460460
let msg = format!(
461461
"reached the type-length limit while instantiating `{}`",
462462
shrunk

0 commit comments

Comments
 (0)