Avoid Option::is_none_or for a while

This commit is contained in:
Laurențiu Nicola 2024-09-02 20:04:35 +03:00
parent 5461f494e6
commit d398b8f3f9

View file

@ -287,7 +287,7 @@ pub(crate) fn const_eval_discriminant_variant(
}
let repr = db.enum_data(loc.parent).repr;
let is_signed = repr.and_then(|repr| repr.int).is_none_or(|int| int.is_signed());
let is_signed = IsNoneOr::is_none_or(repr.and_then(|repr| repr.int), |int| int.is_signed());
let mir_body = db.monomorphized_mir_body(
def,