Skip to content

Commit c9c14d0

Browse files
committed
Small refactor
1 parent 98a11e0 commit c9c14d0

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

compiler/rustc_trait_selection/src/traits/object_safety.rs

+1-2
Original file line numberDiff line numberDiff line change
@@ -439,8 +439,7 @@ fn virtual_call_violation_for_method<'tcx>(
439439
return Some(MethodViolationCode::WhereClauseReferencesSelf);
440440
}
441441

442-
let receiver_ty =
443-
tcx.liberate_late_bound_regions(method.def_id, sig.map_bound(|sig| sig.inputs()[0]));
442+
let receiver_ty = tcx.liberate_late_bound_regions(method.def_id, sig.input(0));
444443

445444
// Until `unsized_locals` is fully implemented, `self: Self` can't be dispatched on.
446445
// However, this is already considered object-safe. We allow it as a special case here.

0 commit comments

Comments
 (0)