diff options
| author | Vadim Petrochenkov <vadim.petrochenkov@gmail.com> | 2016-03-06 15:54:44 +0300 |
|---|---|---|
| committer | Vadim Petrochenkov <vadim.petrochenkov@gmail.com> | 2016-05-25 22:17:58 +0300 |
| commit | dcea4b26268d19b32c7e29bf063638fa5e3bbd91 (patch) | |
| tree | e7c7ea6d66b707e8a99b78c92abcb012613282c4 | |
| parent | 1a1de5bf899a15cd97f2a113add070bec46cf209 (diff) | |
| download | rust-dcea4b26268d19b32c7e29bf063638fa5e3bbd91.tar.gz rust-dcea4b26268d19b32c7e29bf063638fa5e3bbd91.zip | |
Fix rebase
| -rw-r--r-- | src/librustc_resolve/lib.rs | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/src/librustc_resolve/lib.rs b/src/librustc_resolve/lib.rs index 41cc5462816..215109f282d 100644 --- a/src/librustc_resolve/lib.rs +++ b/src/librustc_resolve/lib.rs @@ -67,7 +67,7 @@ use syntax::ast::{Arm, BindingMode, Block, Crate, Expr, ExprKind}; use syntax::ast::{FnDecl, ForeignItem, ForeignItemKind, Generics}; use syntax::ast::{Item, ItemKind, ImplItem, ImplItemKind}; use syntax::ast::{Local, Pat, PatKind, Path}; -use syntax::ast::{PathSegment, PathParameters, SelfKind, TraitItemKind, TraitRef, Ty, TyKind}; +use syntax::ast::{PathSegment, PathParameters, TraitItemKind, TraitRef, Ty, TyKind}; use std::collections::{HashMap, HashSet}; use std::cell::{Cell, RefCell}; @@ -607,7 +607,7 @@ impl<'a, 'v> Visitor<'v> for Resolver<'a> { } FnKind::Method(_, sig, _) => { self.visit_generics(&sig.generics); - MethodRibKind(sig.explicit_self.node == SelfKind::Static) + MethodRibKind(!sig.decl.has_self()) } FnKind::Closure => ClosureRibKind(node_id), }; @@ -1676,9 +1676,7 @@ impl<'a> Resolver<'a> { let type_parameters = HasTypeParameters(&sig.generics, FnSpace, - MethodRibKind( - sig.explicit_self.node == - SelfKind::Static)); + MethodRibKind(!sig.decl.has_self())); this.with_type_parameter_rib(type_parameters, |this| { visit::walk_trait_item(this, trait_item) }); @@ -2007,9 +2005,7 @@ impl<'a> Resolver<'a> { let type_parameters = HasTypeParameters(&sig.generics, FnSpace, - MethodRibKind( - sig.explicit_self.node == - SelfKind::Static)); + MethodRibKind(!sig.decl.has_self())); this.with_type_parameter_rib(type_parameters, |this| { visit::walk_impl_item(this, impl_item); }); |
