Don't delete any lifetimes with bounds
This commit is contained in:
parent
0943a6b188
commit
de2575f35d
2 changed files with 2 additions and 6 deletions
|
@ -2567,8 +2567,9 @@ impl<'a: 'ast, 'ast, 'tcx> LateResolutionVisitor<'a, '_, 'ast, 'tcx> {
|
|||
debug!(?param.ident, ?param.ident.span, ?use_span);
|
||||
|
||||
let elidable = matches!(use_ctxt, LifetimeCtxt::Ref);
|
||||
let deletion_span =
|
||||
if param.bounds.is_empty() { deletion_span() } else { None };
|
||||
|
||||
let deletion_span = deletion_span();
|
||||
self.r.lint_buffer.buffer_lint_with_diagnostic(
|
||||
lint::builtin::SINGLE_USE_LIFETIMES,
|
||||
param.id,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue