@@ -4615,7 +4615,7 @@ impl<'a, 'gcx, 'tcx> FnCtxt<'a, 'gcx, 'tcx> {
46154615 local : & ' gcx hir:: Local ,
46164616 init : & ' gcx hir:: Expr ) -> Ty < ' tcx >
46174617 {
4618- // FIXME(tschottdorf): contains_explicit_ref_binding() must be removed
4618+ // FIXME(tschottdorf): ` contains_explicit_ref_binding()` must be removed
46194619 // for #42640 (default match binding modes).
46204620 //
46214621 // See #44848.
@@ -4660,7 +4660,7 @@ impl<'a, 'gcx, 'tcx> FnCtxt<'a, 'gcx, 'tcx> {
46604660 }
46614661
46624662 pub fn check_stmt ( & self , stmt : & ' gcx hir:: Stmt ) {
4663- // Don't do all the complex logic below for DeclItem.
4663+ // Don't do all the complex logic below for ` DeclItem` .
46644664 match stmt. node {
46654665 hir:: StmtKind :: Decl ( ref decl, _) => {
46664666 if let hir:: DeclKind :: Item ( _) = decl. node {
@@ -4672,7 +4672,7 @@ impl<'a, 'gcx, 'tcx> FnCtxt<'a, 'gcx, 'tcx> {
46724672
46734673 self . warn_if_unreachable ( stmt. node . id ( ) , stmt. span , "statement" ) ;
46744674
4675- // Hide the outer diverging and has_errors flags.
4675+ // Hide the outer diverging and ` has_errors` flags.
46764676 let old_diverges = self . diverges . get ( ) ;
46774677 let old_has_errors = self . has_errors . get ( ) ;
46784678 self . diverges . set ( Diverges :: Maybe ) ;
@@ -4684,19 +4684,20 @@ impl<'a, 'gcx, 'tcx> FnCtxt<'a, 'gcx, 'tcx> {
46844684 hir:: DeclKind :: Local ( ref l) => {
46854685 self . check_decl_local ( & l) ;
46864686 }
4687- hir:: DeclKind :: Item ( _) => { /* ignore for now */ }
4687+ // Ignore for now.
4688+ hir:: DeclKind :: Item ( _) => ( )
46884689 }
46894690 }
46904691 hir:: StmtKind :: Expr ( ref expr, _) => {
4691- // Check with expected type of ()
4692+ // Check with expected type of `()`.
46924693 self . check_expr_has_type_or_error ( & expr, self . tcx . mk_unit ( ) ) ;
46934694 }
46944695 hir:: StmtKind :: Semi ( ref expr, _) => {
46954696 self . check_expr ( & expr) ;
46964697 }
46974698 }
46984699
4699- // Combine the diverging and has_error flags.
4700+ // Combine the diverging and ` has_error` flags.
47004701 self . diverges . set ( self . diverges . get ( ) | old_diverges) ;
47014702 self . has_errors . set ( self . has_errors . get ( ) | old_has_errors) ;
47024703 }
0 commit comments