Handle empty where-clause better
This commit is contained in:
parent
8506b7d4e0
commit
9c47afe9fa
23 changed files with 78 additions and 59 deletions
|
@ -2293,7 +2293,8 @@ impl<'tcx> LateLintPass<'tcx> for ExplicitOutlivesRequirements {
|
|||
|
||||
// If all predicates are inferable, drop the entire clause
|
||||
// (including the `where`)
|
||||
if hir_generics.has_where_clause && dropped_predicate_count == num_predicates {
|
||||
if hir_generics.has_where_clause_predicates && dropped_predicate_count == num_predicates
|
||||
{
|
||||
let where_span = hir_generics
|
||||
.where_clause_span()
|
||||
.expect("span of (nonempty) where clause should exist");
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue