X-Git-Url: https://git.lizzy.rs/?a=blobdiff_plain;f=src%2Flibrustc_ast_passes%2Fast_validation.rs;h=69d5610e0160185a3224cdaf38b3832c25ca79c7;hb=43079147f4fcc5c0a9019fb39acdc8aa3c384f65;hp=0463ad7fb7b6f1226df06b0376b8e0d004856e82;hpb=5703b7aafb70e77547e8f03876a5911a2e89a2a5;p=rust.git diff --git a/src/librustc_ast_passes/ast_validation.rs b/src/librustc_ast_passes/ast_validation.rs index 0463ad7fb7b..69d5610e016 100644 --- a/src/librustc_ast_passes/ast_validation.rs +++ b/src/librustc_ast_passes/ast_validation.rs @@ -6,6 +6,11 @@ // This pass is supposed to perform only simple checks not requiring name resolution // or type checking or some other kind of complex analysis. +use rustc_ast::ast::*; +use rustc_ast::attr; +use rustc_ast::expand::is_proc_macro_attr; +use rustc_ast::visit::{self, AssocCtxt, FnCtxt, FnKind, Visitor}; +use rustc_ast::walk_list; use rustc_ast_pretty::pprust; use rustc_data_structures::fx::FxHashMap; use rustc_errors::{error_code, struct_span_err, Applicability}; @@ -16,11 +21,6 @@ use rustc_span::symbol::{kw, sym}; use rustc_span::Span; use std::mem; -use syntax::ast::*; -use syntax::attr; -use syntax::expand::is_proc_macro_attr; -use syntax::visit::{self, AssocCtxt, FnCtxt, FnKind, Visitor}; -use syntax::walk_list; const MORE_EXTERN: &str = "for more information, visit https://doc.rust-lang.org/std/keyword.extern.html"; @@ -976,7 +976,7 @@ fn visit_foreign_item(&mut self, fi: &'a ForeignItem) { ForeignItemKind::Static(_, _, body) => { self.check_foreign_kind_bodyless(fi.ident, "static", body.as_ref().map(|b| b.span)); } - ForeignItemKind::Const(..) | ForeignItemKind::Macro(..) => {} + ForeignItemKind::Macro(..) => {} } visit::walk_foreign_item(self, fi)