conflict fixes

This commit is contained in:
gaurikholkar 2017-06-28 12:18:21 -07:00
parent e8b8f30373
commit 5841021f07

View File

@ -107,7 +107,8 @@ pub fn try_report_named_anon_conflict(&self, error: &RegionResolutionError<'tcx>
// FIXME(#42703) - Need to handle certain cases here.
let ret_ty = self.tcx.type_of(scope_def_id);
match ret_ty.sty {
ty::TyFnDef(_, _, sig) => {
ty::TyFnDef(_, _) => {
let sig = ret_ty.fn_sig(self.tcx);
let late_bound_regions = self.tcx
.collect_referenced_late_bound_regions(&sig.output());
if late_bound_regions.iter().any(|r| *r == br) {