diff options
| author | Florian Diebold <flodiebold@gmail.com> | 2016-11-21 19:04:07 +0100 |
|---|---|---|
| committer | Florian Diebold <florian.diebold@freiheit.com> | 2016-11-29 13:04:27 +0100 |
| commit | 8d5ca62dcdc212d6068c7e3340cf6dbb8577adce (patch) | |
| tree | 5315173fb929e39bc814865d1e7e84c9119251f0 /src | |
| parent | 78b54c07e5cfc0287d87b132dc7774aed6b36922 (diff) | |
| download | rust-8d5ca62dcdc212d6068c7e3340cf6dbb8577adce.tar.gz rust-8d5ca62dcdc212d6068c7e3340cf6dbb8577adce.zip | |
Fix some comments
Diffstat (limited to 'src')
| -rw-r--r-- | src/librustc/hir/map/mod.rs | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/src/librustc/hir/map/mod.rs b/src/librustc/hir/map/mod.rs index a78f4de475a..421d5bdad0c 100644 --- a/src/librustc/hir/map/mod.rs +++ b/src/librustc/hir/map/mod.rs @@ -266,7 +266,7 @@ impl<'ast> Map<'ast> { if let Some(last_id) = last_expr { // The body of the item may have a separate dep node - // (Note that impl/trait items don't currently have + // (Note that trait items don't currently have // their own dep node, so there's also just one // HirBody node for all the items) if self.is_body(last_id, item) { @@ -282,9 +282,6 @@ impl<'ast> Map<'ast> { if let Some(last_id) = last_expr { // The body of the item may have a separate dep node - // (Note that impl/trait items don't currently have - // their own dep node, so there's also just one - // HirBody node for all the items) if self.is_impl_item_body(last_id, item) { return DepNode::HirBody(def_id); } @@ -373,9 +370,9 @@ impl<'ast> Map<'ast> { fn is_body(&self, node_id: NodeId, item: &Item) -> bool { match item.node { ItemFn(_, _, _, _, _, body) => body.node_id() == node_id, - // Since trait/impl items currently don't get their own dep nodes, + // Since trait items currently don't get their own dep nodes, // we check here whether node_id is the body of any of the items. - // Once they get their own dep nodes, this can go away + // If they get their own dep nodes, this can go away ItemTrait(_, _, _, ref trait_items) => { trait_items.iter().any(|trait_item| { match trait_item.node { MethodTraitItem(_, Some(body)) => body.node_id() == node_id, |
