Skip to content

Commit

Permalink
Change to a multi-trait approach
Browse files Browse the repository at this point in the history
[breaking-change] for lint authors

You must now implement LateLintPass or EarlyLintPass as well as LintPass and use either register_late_lint_pass or register_early_lint_pass, rather than register_lint_pass.
  • Loading branch information
nrc committed Sep 17, 2015
1 parent c1084a3 commit a642d85
Show file tree
Hide file tree
Showing 11 changed files with 266 additions and 150 deletions.
4 changes: 3 additions & 1 deletion src/librustc/lint/builtin.rs
Expand Up @@ -14,7 +14,7 @@
//! compiler code, rather than using their own custom pass. Those
//! lints are all available in `rustc_lint::builtin`.

use lint::{LintPass, LintArray};
use lint::{LintPass, LateLintPass, LintArray};

declare_lint! {
pub UNUSED_IMPORTS,
Expand Down Expand Up @@ -138,3 +138,5 @@ impl LintPass for HardwiredLints {
)
}
}

impl LateLintPass for HardwiredLints {}

0 comments on commit a642d85

Please sign in to comment.