Use is_none instead of if let
This commit is contained in:
parent
9b98af84c4
commit
101dd7bad9
1 changed files with 1 additions and 1 deletions
|
|
@ -2289,7 +2289,7 @@ impl<'a, 'tcx> InferCtxt<'a, 'tcx> {
|
|||
let span = self.tcx.def_span(generator_did);
|
||||
|
||||
// Do not ICE on closure typeck (#66868).
|
||||
if let None = self.tcx.hir().as_local_hir_id(generator_did) {
|
||||
if self.tcx.hir().as_local_hir_id(generator_did).is_none() {
|
||||
return false;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue