Skip to content

query for def_span #41593

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 7 commits into from
Apr 30, 2017
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
removed custom functions and comment
  • Loading branch information
hackeryarn committed Apr 29, 2017
commit d3b7af0e263627a2aa42952aced8439dbfad84d3
1 change: 0 additions & 1 deletion src/librustc/dep_graph/dep_node.rs
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,6 @@ pub enum DepNode<D: Clone + Debug> {
// not a hotspot.
ProjectionCache { def_ids: Vec<D> },

// Depnodes for MetaData
DescribeDef(D),
DefSpan(D),
}
Expand Down
14 changes: 3 additions & 11 deletions src/librustc/ty/maps.rs
Original file line number Diff line number Diff line change
Expand Up @@ -576,8 +576,8 @@ define_maps! { <'tcx>
[] def_symbol_name: SymbolName(DefId) -> ty::SymbolName,
[] symbol_name: symbol_name_dep_node(ty::Instance<'tcx>) -> ty::SymbolName,

[] describe_def: describe_def(DefId) -> Option<Def>,
[] def_span: def_span(DefId) -> Span
[] describe_def: DescribeDef(DefId) -> Option<Def>,
[] def_span: DefSpan(DefId) -> Span
}

fn coherent_trait_dep_node((_, def_id): (CrateNum, DefId)) -> DepNode<DefId> {
Expand Down Expand Up @@ -608,12 +608,4 @@ fn typeck_item_bodies_dep_node(_: CrateNum) -> DepNode<DefId> {

fn const_eval_dep_node((def_id, _): (DefId, &Substs)) -> DepNode<DefId> {
DepNode::ConstEval(def_id)
}

fn describe_def(def_id: DefId) -> DepNode<DefId> {
DepNode::DescribeDef(def_id)
}

fn def_span(def_id: DefId) -> DepNode<DefId> {
DepNode::DefSpan(def_id)
}
}