rustc_privacy: fix compilation

This commit is contained in:
Florian Diebold 2016-10-29 14:35:54 +02:00 committed by Florian Diebold
parent dd6a57ce2a
commit 0cdd1d4bc1

View File

@ -30,7 +30,7 @@
use rustc::hir::{self, PatKind};
use rustc::hir::def::{self, Def, CtorKind};
use rustc::hir::def_id::DefId;
use rustc::hir::intravisit::{self, Visitor};
use rustc::hir::intravisit::{self, Visitor, NestedVisitMode};
use rustc::hir::itemlikevisit::DeepVisitor;
use rustc::hir::pat_util::EnumerateAndAdjustIterator;
use rustc::lint;
@ -120,8 +120,8 @@ fn reach<'b>(&'b mut self, item_id: ast::NodeId)
impl<'a, 'tcx> Visitor<'tcx> for EmbargoVisitor<'a, 'tcx> {
/// We want to visit items in the context of their containing
/// module and so forth, so supply a crate for doing a deep walk.
fn nested_visit_map(&mut self) -> Option<&hir::map::Map<'tcx>> {
Some(&self.tcx.map)
fn nested_visit_map(&mut self) -> Option<(&hir::map::Map<'tcx>, NestedVisitMode)> {
Some((&self.tcx.map, NestedVisitMode::All))
}
fn visit_item(&mut self, item: &'tcx hir::Item) {
@ -432,8 +432,8 @@ fn check_method(&mut self, span: Span, method_def_id: DefId) {
impl<'a, 'tcx> Visitor<'tcx> for PrivacyVisitor<'a, 'tcx> {
/// We want to visit items in the context of their containing
/// module and so forth, so supply a crate for doing a deep walk.
fn nested_visit_map(&mut self) -> Option<&hir::map::Map<'tcx>> {
Some(&self.tcx.map)
fn nested_visit_map(&mut self) -> Option<(&hir::map::Map<'tcx>, NestedVisitMode)> {
Some((&self.tcx.map, NestedVisitMode::All))
}
fn visit_item(&mut self, item: &'tcx hir::Item) {
@ -640,8 +640,8 @@ fn visit_expr(&mut self, _: &hir::Expr) {}
impl<'a, 'tcx> Visitor<'tcx> for ObsoleteVisiblePrivateTypesVisitor<'a, 'tcx> {
/// We want to visit items in the context of their containing
/// module and so forth, so supply a crate for doing a deep walk.
fn nested_visit_map(&mut self) -> Option<&hir::map::Map<'tcx>> {
Some(&self.tcx.map)
fn nested_visit_map(&mut self) -> Option<(&hir::map::Map<'tcx>, NestedVisitMode)> {
Some((&self.tcx.map, NestedVisitMode::All))
}
fn visit_item(&mut self, item: &'tcx hir::Item) {