Change two <= to == for clarity

This commit is contained in:
Samuel Moelius 2022-10-31 20:12:37 -04:00
parent 2c44398487
commit c0d928561c

View File

@ -337,7 +337,7 @@ fn could_use_elision<'tcx>(
let elidable_lts = named_lifetime_occurrences(&input_lts)
.into_iter()
.filter_map(|(def_id, occurrences)| {
if occurrences <= 1 && (input_lts.len() <= 1 || !output_lts.contains(&RefLt::Named(def_id))) {
if occurrences == 1 && (input_lts.len() == 1 || !output_lts.contains(&RefLt::Named(def_id))) {
Some((
def_id,
input_visitor