use rustc::lint::*;
+use rustc::{declare_lint, lint_array};
use syntax::ast;
-use utils::{differing_macro_contexts, in_macro, snippet_opt, span_note_and_lint};
+use crate::utils::{differing_macro_contexts, in_macro, snippet_opt, span_note_and_lint};
use syntax::ptr::P;
/// **What it does:** Checks for use of the non-existent `=*`, `=!` and `=-`
/// ```rust,ignore
/// a =- 42; // confusing, should it be `a -= 42` or `a = -42`?
/// ```
-declare_lint! {
+declare_clippy_lint! {
pub SUSPICIOUS_ASSIGNMENT_FORMATTING,
- Warn,
+ style,
"suspicious formatting of `*=`, `-=` or `!=`"
}
/// if bar { // this is the `else` block of the previous `if`, but should it be?
/// }
/// ```
-declare_lint! {
+declare_clippy_lint! {
pub SUSPICIOUS_ELSE_FORMATTING,
- Warn,
+ style,
"suspicious formatting of `else if`"
}
/// -4, -5, -6
/// ];
/// ```
-declare_lint! {
+declare_clippy_lint! {
pub POSSIBLE_MISSING_COMMA,
- Warn,
+ correctness,
"possible missing comma in array"
}