Add clippy version to Clippy's lint list

This commit is contained in:
xFrednet 2021-10-12 23:01:44 +02:00
parent 7c1e62d962
commit 8565fc468e
No known key found for this signature in database
GPG Key ID: FCDCBF29AF64D601
3 changed files with 6 additions and 2 deletions

View File

@ -18,6 +18,7 @@ static DEC_CLIPPY_LINT_RE: SyncLazy<Regex> = SyncLazy::new(|| {
r#"(?x)
declare_clippy_lint!\s*[\{(]
(?:\s+///.*)*
(?:\s*\#\[clippy::version\s*=\s*"[^"]*"\])?
\s+pub\s+(?P<name>[A-Z_][A-Z_0-9]*)\s*,\s*
(?P<cat>[a-z_]+)\s*,\s*
"(?P<desc>(?:[^"\\]+|\\(?s).(?-s))*)"\s*[})]

View File

@ -146,7 +146,7 @@ declare_clippy_lint! {
/// "docs": " ### What it does\nCollects metadata about clippy lints for the website. [...] "
/// }
/// ```
#[clippy::version = "0.1.56"]
#[clippy::version = "1.56.0"]
pub INTERNAL_METADATA_COLLECTOR,
internal_warn,
"A busy bee collection metadata about lints"

View File

@ -339,7 +339,10 @@ Otherwise, have a great day =^.^=
<span class="label label-default label-applicability">{{lint.applicability.applicability}}</span>
<a href="https://doc.rust-lang.org/nightly/nightly-rustc/rustc_lint_defs/enum.Applicability.html#variants">(?)</a>
</div>
<!-- TODO xFrednet 2021-05-19: Somehow collect and show the version See rust-clippy#6492 -->
<!-- Clippy version -->
<div class="lint-additional-info-item">
Rust version: <span class="label label-default label-applicability">{{lint.version}}</span>
</div>
<!-- Open related issues -->
<div class="lint-additional-info-item">
<a href="https://github.com/rust-lang/rust-clippy/issues?q=is%3Aissue+{{lint.id}}">Related Issues</a>