Add hir::Attribute
This commit is contained in:
parent
53b2c7cc95
commit
d50c0a5480
89 changed files with 1144 additions and 659 deletions
|
@ -50,7 +50,7 @@ use rustc_middle::{bug, span_bug};
|
|||
use rustc_span::Span;
|
||||
use rustc_span::symbol::{Symbol, sym};
|
||||
use tracing::debug;
|
||||
use {rustc_ast as ast, rustc_graphviz as dot, rustc_hir as hir};
|
||||
use {rustc_graphviz as dot, rustc_hir as hir};
|
||||
|
||||
use crate::errors;
|
||||
|
||||
|
@ -106,7 +106,7 @@ struct IfThisChanged<'tcx> {
|
|||
}
|
||||
|
||||
impl<'tcx> IfThisChanged<'tcx> {
|
||||
fn argument(&self, attr: &ast::Attribute) -> Option<Symbol> {
|
||||
fn argument(&self, attr: &hir::Attribute) -> Option<Symbol> {
|
||||
let mut value = None;
|
||||
for list_item in attr.meta_item_list().unwrap_or_default() {
|
||||
match list_item.ident() {
|
||||
|
|
|
@ -19,11 +19,13 @@
|
|||
//! Errors are reported if we are in the suitable configuration but
|
||||
//! the required condition is not met.
|
||||
|
||||
use rustc_ast::{self as ast, Attribute, MetaItemInner};
|
||||
use rustc_ast::{self as ast, MetaItemInner};
|
||||
use rustc_data_structures::fx::FxHashSet;
|
||||
use rustc_data_structures::unord::UnordSet;
|
||||
use rustc_hir::def_id::LocalDefId;
|
||||
use rustc_hir::{ImplItemKind, ItemKind as HirItem, Node as HirNode, TraitItemKind, intravisit};
|
||||
use rustc_hir::{
|
||||
Attribute, ImplItemKind, ItemKind as HirItem, Node as HirNode, TraitItemKind, intravisit,
|
||||
};
|
||||
use rustc_middle::dep_graph::{DepNode, DepNodeExt, label_strs};
|
||||
use rustc_middle::hir::nested_filter;
|
||||
use rustc_middle::ty::TyCtxt;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue