File tree Expand file tree Collapse file tree 2 files changed +21
-20
lines changed Expand file tree Collapse file tree 2 files changed +21
-20
lines changed Original file line number Diff line number Diff line change 55extern crate rustc;
66use rustc:: lint:: { LintArray , LintPass } ;
77
8- #[ macro_use]
9- extern crate clippy_lints;
10-
11- declare_clippy_lint ! {
12- pub TEST_LINT ,
13- correctness,
14- ""
8+ declare_tool_lint ! {
9+ pub clippy:: TEST_LINT ,
10+ Warn ,
11+ "" ,
12+ report_in_external_macro: true
1513}
1614
17- declare_clippy_lint ! {
18- pub TEST_LINT_REGISTERED ,
19- correctness,
20- ""
15+ declare_tool_lint ! {
16+ pub clippy:: TEST_LINT_REGISTERED ,
17+ Warn ,
18+ "" ,
19+ report_in_external_macro: true
2120}
2221
23- declare_clippy_lint ! {
24- pub TEST_LINT_REGISTERED_ONLY_IMPL ,
25- correctness,
26- ""
22+ declare_tool_lint ! {
23+ pub clippy:: TEST_LINT_REGISTERED_ONLY_IMPL ,
24+ Warn ,
25+ "" ,
26+ report_in_external_macro: true
2727}
2828
2929pub struct Pass ;
Original file line number Diff line number Diff line change 11error: the lint `TEST_LINT` is not added to any `LintPass`
2- --> $DIR/lint_without_lint_pass.rs:11 :1
2+ --> $DIR/lint_without_lint_pass.rs:8 :1
33 |
4- LL | / declare_clippy_lint! {
5- LL | | pub TEST_LINT,
6- LL | | correctness,
7- LL | | ""
4+ LL | / declare_tool_lint! {
5+ LL | | pub clippy::TEST_LINT,
6+ LL | | Warn,
7+ LL | | "",
8+ LL | | report_in_external_macro: true
89LL | | }
910 | |_^
1011 |
You can’t perform that action at this time.
0 commit comments