]> git.lizzy.rs Git - rust.git/commitdiff
rustc: don't allow(non_camel_case_types) in resolve.
authorEduard Burtescu <edy.burt@gmail.com>
Thu, 18 Dec 2014 17:17:41 +0000 (19:17 +0200)
committerEduard Burtescu <edy.burt@gmail.com>
Sat, 20 Dec 2014 05:11:03 +0000 (07:11 +0200)
src/librustc/middle/resolve.rs

index e1e376c537cbab100cd2653343f60c43802201bb..49a8facffd26a802c24b095f5a09ba788cee88f6 100644 (file)
@@ -8,8 +8,6 @@
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 
-#![allow(non_camel_case_types)]
-
 pub use self::PrivateDep::*;
 pub use self::ImportUse::*;
 pub use self::TraitItemKind::*;
 pub type DefMap = RefCell<NodeMap<Def>>;
 
 #[deriving(Copy)]
-struct binding_info {
+struct BindingInfo {
     span: Span,
     binding_mode: BindingMode,
 }
 
 // Map from the name in a pattern to its binding mode.
-type BindingMap = HashMap<Name,binding_info>;
+type BindingMap = HashMap<Name, BindingInfo>;
 
 // Trait method resolution
 pub type TraitMap = NodeMap<Vec<DefId> >;
@@ -4809,9 +4807,10 @@ fn binding_mode_map(&mut self, pat: &Pat) -> BindingMap {
         let mut result = HashMap::new();
         pat_bindings(&self.def_map, pat, |binding_mode, _id, sp, path1| {
             let name = mtwt::resolve(path1.node);
-            result.insert(name,
-                          binding_info {span: sp,
-                                        binding_mode: binding_mode});
+            result.insert(name, BindingInfo {
+                span: sp,
+                binding_mode: binding_mode
+            });
         });
         return result;
     }