Skip to content

Commit be08fbc

Browse files
committed
Fix checks
1 parent b3fa9c2 commit be08fbc

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

‎compiler/rustc_query_impl/src/handle_cycle_error.rs‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ pub(crate) fn clauses_of<'tcx>(
5050
_: QueryCycle<'tcx>,
5151
err: Diag<'_>,
5252
) -> rustc_middle::ty::GenericClauses<'tcx> {
53-
if def_id.as_local().is_some_and(|def_id| !tcx.is_delegation(def_id)) {
53+
if def_id.as_local().is_none_or(|def_id| !tcx.is_delegation(def_id)) {
5454
err.emit().raise_fatal();
5555
}
5656

@@ -64,7 +64,7 @@ pub(crate) fn explicit_clauses_of<'tcx>(
6464
_: QueryCycle<'tcx>,
6565
err: Diag<'_>,
6666
) -> rustc_middle::ty::GenericClauses<'tcx> {
67-
if def_id.as_local().is_some_and(|def_id| !tcx.is_delegation(def_id)) {
67+
if def_id.as_local().is_none_or(|def_id| !tcx.is_delegation(def_id)) {
6868
err.emit().raise_fatal();
6969
}
7070

0 commit comments

Comments
 (0)