Add explanatory comment
This commit is contained in:
parent
2884a74d08
commit
bbe3be9bf8
1 changed files with 2 additions and 0 deletions
|
@ -941,6 +941,8 @@ impl<'a, 'tcx> FnCtxt<'a, 'tcx> {
|
||||||
exprs.len()
|
exprs.len()
|
||||||
);
|
);
|
||||||
|
|
||||||
|
// The following check fixes #88097, where the compiler erroneously
|
||||||
|
// attempted to coerce a closure type to itself via a function pointer.
|
||||||
if prev_ty == new_ty {
|
if prev_ty == new_ty {
|
||||||
return Ok(prev_ty);
|
return Ok(prev_ty);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue