Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
matthiaskrgr committed Oct 28, 2019
1 parent 66df92a commit ece5f86
Show file tree
Hide file tree
Showing 4 changed files with 3 additions and 6 deletions.
2 changes: 0 additions & 2 deletions clippy_lints/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,6 @@ extern crate rustc_typeck;
#[allow(unused_extern_crates)]
extern crate syntax;
#[allow(unused_extern_crates)]
extern crate syntax_expand;
#[allow(unused_extern_crates)]
extern crate syntax_pos;

use rustc::lint::{self, LintId};
Expand Down
2 changes: 1 addition & 1 deletion clippy_lints/src/misc.rs
Original file line number Diff line number Diff line change
Expand Up @@ -596,7 +596,7 @@ fn is_used(cx: &LateContext<'_, '_>, expr: &Expr) -> bool {
/// Tests whether an expression is in a macro expansion (e.g., something
/// generated by `#[derive(...)]` or the like).
fn in_attributes_expansion(expr: &Expr) -> bool {
use syntax_expand::hygiene::MacroKind;
use syntax_pos::hygiene::MacroKind;
if expr.span.from_expansion() {
let data = expr.span.ctxt().outer_expn_data();

Expand Down
3 changes: 1 addition & 2 deletions clippy_lints/src/types.rs
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,7 @@ use syntax::ast::{FloatTy, IntTy, LitIntType, LitKind, UintTy};
use syntax::errors::DiagnosticBuilder;
use syntax::source_map::Span;
use syntax::symbol::{sym, Symbol};
use syntax_expand::base::MacroKind;
use syntax_expand::hygiene::ExpnKind;
use syntax_pos::hygiene::{ExpnKind, MacroKind};

use crate::consts::{constant, Constant};
use crate::utils::paths;
Expand Down
2 changes: 1 addition & 1 deletion clippy_lints/src/utils/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ use syntax::ast::{self, LitKind};
use syntax::attr;
use syntax::source_map::{Span, DUMMY_SP};
use syntax::symbol::{kw, Symbol};
use syntax_expand::hygiene::ExpnKind;
use syntax_pos::hygiene::ExpnKind;

use crate::consts::{constant, Constant};
use crate::reexport::*;
Expand Down

0 comments on commit ece5f86

Please sign in to comment.