Open
Description
We have a handful of utils for emitting lints: span_lint
, span_lint_and_help
, etc. We'd like to replace these with one new util named span_clippy_lint
. It was already implemented in #7668, but not yet merged.
Goals
- Be more consistent with rustc
- Potentially improve perf since allowed lints stop before computing output messages
- Enable trimmed paths (Enable trimmed paths #7798)
Question: Should we use .emit()
like rustc, or use Drop
to emit automatically?
Steps
- Add
span_clippy_lint
from Enable trimmed paths #7668 and patch the metadata collector to work with it - Change all
span_lint_*
calls tospan_clippy_lint
- divide this into smaller parts?
- Remove
span_lint*
utils and metadata collector support