diff options
| author | achernyak <artemchernyak@gmail.com> | 2017-05-03 09:01:49 -0500 |
|---|---|---|
| committer | achernyak <artemchernyak@gmail.com> | 2017-05-03 09:01:49 -0500 |
| commit | c72a16b8e2e1febb300cab5b97fc3265a463e775 (patch) | |
| tree | e8a64c24652d97c35523312a69bdaecc28eed5a0 /src/librustc | |
| parent | a12a55f519baea94c049fcda6d14dcd56110f39d (diff) | |
| download | rust-c72a16b8e2e1febb300cab5b97fc3265a463e775.tar.gz rust-c72a16b8e2e1febb300cab5b97fc3265a463e775.zip | |
fn_arg_names
Diffstat (limited to 'src/librustc')
| -rw-r--r-- | src/librustc/dep_graph/dep_node.rs | 2 | ||||
| -rw-r--r-- | src/librustc/middle/cstore.rs | 2 | ||||
| -rw-r--r-- | src/librustc/ty/maps.rs | 7 |
3 files changed, 9 insertions, 2 deletions
diff --git a/src/librustc/dep_graph/dep_node.rs b/src/librustc/dep_graph/dep_node.rs index fb8678ce93e..591c128a165 100644 --- a/src/librustc/dep_graph/dep_node.rs +++ b/src/librustc/dep_graph/dep_node.rs @@ -158,6 +158,7 @@ pub enum DepNode<D: Clone + Debug> { ConstIsRvaluePromotableToStatic(D), IsMirAvailable(D), ItemAttrs(D), + FnArgNames(D), } impl<D: Clone + Debug> DepNode<D> { @@ -269,6 +270,7 @@ impl<D: Clone + Debug> DepNode<D> { Stability(ref d) => op(d).map(Stability), Deprecation(ref d) => op(d).map(Deprecation), ItemAttrs(ref d) => op(d).map(ItemAttrs), + FnArgNames(ref d) => op(d).map(FnArgNames), ItemBodyNestedBodies(ref d) => op(d).map(ItemBodyNestedBodies), ConstIsRvaluePromotableToStatic(ref d) => op(d).map(ConstIsRvaluePromotableToStatic), IsMirAvailable(ref d) => op(d).map(IsMirAvailable), diff --git a/src/librustc/middle/cstore.rs b/src/librustc/middle/cstore.rs index e30b4b2818e..00904f54061 100644 --- a/src/librustc/middle/cstore.rs +++ b/src/librustc/middle/cstore.rs @@ -182,7 +182,6 @@ pub trait CrateStore { fn visibility(&self, def: DefId) -> ty::Visibility; fn visible_parent_map<'a>(&'a self) -> ::std::cell::Ref<'a, DefIdMap<DefId>>; fn item_generics_cloned(&self, def: DefId) -> ty::Generics; - fn fn_arg_names(&self, did: DefId) -> Vec<ast::Name>; // trait info fn implementations_of_trait(&self, filter: Option<DefId>) -> Vec<DefId>; @@ -308,7 +307,6 @@ impl CrateStore for DummyCrateStore { } fn item_generics_cloned(&self, def: DefId) -> ty::Generics { bug!("item_generics_cloned") } - fn fn_arg_names(&self, did: DefId) -> Vec<ast::Name> { bug!("fn_arg_names") } // trait info fn implementations_of_trait(&self, filter: Option<DefId>) -> Vec<DefId> { vec![] } diff --git a/src/librustc/ty/maps.rs b/src/librustc/ty/maps.rs index 948df617867..43f6c94b8b0 100644 --- a/src/librustc/ty/maps.rs +++ b/src/librustc/ty/maps.rs @@ -341,6 +341,12 @@ impl<'tcx> QueryDescription for queries::item_attrs<'tcx> { } } +impl<'tcx> QueryDescription for queries::fn_arg_names<'tcx> { + fn describe(_: TyCtxt, _: DefId) -> String { + bug!("fn_arg_names") + } +} + impl<'tcx> QueryDescription for queries::item_body_nested_bodies<'tcx> { fn describe(tcx: TyCtxt, def_id: DefId) -> String { format!("nested item bodies of `{}`", tcx.item_path_str(def_id)) @@ -791,6 +797,7 @@ define_maps! { <'tcx> [] stability: Stability(DefId) -> Option<attr::Stability>, [] deprecation: Deprecation(DefId) -> Option<attr::Deprecation>, [] item_attrs: ItemAttrs(DefId) -> Rc<[ast::Attribute]>, + [] fn_arg_names: FnArgNames(DefId) -> Vec<ast::Name>, [] item_body_nested_bodies: ItemBodyNestedBodies(DefId) -> Rc<BTreeMap<hir::BodyId, hir::Body>>, [] const_is_rvalue_promotable_to_static: ConstIsRvaluePromotableToStatic(DefId) -> bool, [] is_mir_available: IsMirAvailable(DefId) -> bool, |
