Skip to content

Commit e9ddd82

Browse files
author
Jorge Aparicio
committed
rustc_typeck: unbox closures used in let bindings
1 parent e47035b commit e9ddd82

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/librustc_typeck/check/vtable.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -223,7 +223,7 @@ fn check_object_safety_inner<'tcx>(tcx: &ty::ctxt<'tcx>,
223223
}
224224

225225
// reason (a) above
226-
let check_for_self_ty = |ty| {
226+
let check_for_self_ty = |&: ty| {
227227
if contains_illegal_self_type_reference(tcx, object_trait.def_id(), ty) {
228228
Some(format!(
229229
"cannot call a method (`{}`) whose type contains \

src/librustc_typeck/variance.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -593,7 +593,7 @@ impl<'a, 'tcx> ConstraintContext<'a, 'tcx> {
593593
// parameter (by inspecting parent of its binding declaration
594594
// to see if it is introduced by a type or by a fn/impl).
595595

596-
let check_result = |this:&ConstraintContext| -> bool {
596+
let check_result = |&: this:&ConstraintContext| -> bool {
597597
let tcx = this.terms_cx.tcx;
598598
let decl_id = this.find_binding_for_lifetime(param_id);
599599
// Currently only called on lifetimes; double-checking that.

0 commit comments

Comments
 (0)