Skip to content

Commit f9cf338

Browse files
committed
Responding to reviewer feedback
1 parent 66f91da commit f9cf338

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

compiler/rustc_lint/src/redundant_sizedness_bounds.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -125,6 +125,8 @@ fn check_redundant_sizedness_bounds(
125125
let redundant_sized_params: DefIdMap<_> = type_param_bounds(generics)
126126
.filter(|bound| {
127127
bound.trait_bound.trait_ref.trait_def_id() == Some(redundant_bound)
128+
// Here we wish to compare the variant of the enum `BoundPolarity` whilst
129+
// disregarding the contents of the variant.
128130
&& std::mem::discriminant(&bound.trait_bound.modifiers.polarity)
129131
== std::mem::discriminant(&redundant_bound_polarity)
130132
})

0 commit comments

Comments
 (0)