about summary refs log tree commit diff
path: root/src/libsyntax
diff options
context:
space:
mode:
authorBrian Anderson <banderson@mozilla.com>2012-09-10 15:38:28 -0700
committerBrian Anderson <banderson@mozilla.com>2012-09-10 17:08:36 -0700
commitcb7a5395ddfaa7b8fc40db57b32c22f69780ccd6 (patch)
tree4c79be0560610f8ae49a16670ff9dede47bcaaf1 /src/libsyntax
parent29003c799f41cce948bc043cdd1350ca4bee949e (diff)
downloadrust-cb7a5395ddfaa7b8fc40db57b32c22f69780ccd6.tar.gz
rust-cb7a5395ddfaa7b8fc40db57b32c22f69780ccd6.zip
Convert std::map to camel case
Diffstat (limited to 'src/libsyntax')
-rw-r--r--src/libsyntax/ast_map.rs4
-rw-r--r--src/libsyntax/ast_util.rs4
-rw-r--r--src/libsyntax/attr.rs2
-rw-r--r--src/libsyntax/ext/auto_serialize.rs6
-rw-r--r--src/libsyntax/ext/base.rs4
-rw-r--r--src/libsyntax/ext/expand.rs10
-rw-r--r--src/libsyntax/ext/simplext.rs10
-rw-r--r--src/libsyntax/ext/tt/macro_parser.rs10
-rw-r--r--src/libsyntax/ext/tt/macro_rules.rs2
-rw-r--r--src/libsyntax/ext/tt/transcribe.rs6
-rw-r--r--src/libsyntax/parse/common.rs2
-rw-r--r--src/libsyntax/parse/parser.rs12
-rw-r--r--src/libsyntax/parse/token.rs10
-rw-r--r--src/libsyntax/util/interner.rs6
14 files changed, 44 insertions, 44 deletions
diff --git a/src/libsyntax/ast_map.rs b/src/libsyntax/ast_map.rs
index e0285694460..d9a7543eed4 100644
--- a/src/libsyntax/ast_map.rs
+++ b/src/libsyntax/ast_map.rs
@@ -1,5 +1,5 @@
 use std::map;
-use std::map::hashmap;
+use std::map::HashMap;
 use ast::*;
 use print::pprust;
 use ast_util::{path_to_ident, stmt_id};
@@ -79,7 +79,7 @@ enum ast_node {
     node_block(blk),
 }
 
-type map = std::map::hashmap<node_id, ast_node>;
+type map = std::map::HashMap<node_id, ast_node>;
 type ctx = {map: map, mut path: path,
             mut local_id: uint, diag: span_handler};
 type vt = visit::vt<ctx>;
diff --git a/src/libsyntax/ast_util.rs b/src/libsyntax/ast_util.rs
index 474f0ede109..34ddee55a63 100644
--- a/src/libsyntax/ast_util.rs
+++ b/src/libsyntax/ast_util.rs
@@ -259,8 +259,8 @@ impl def_id : core::to_bytes::IterBytes {
     }
 }
 
-fn new_def_hash<V: Copy>() -> std::map::hashmap<ast::def_id, V> {
-    return std::map::hashmap::<ast::def_id, V>();
+fn new_def_hash<V: Copy>() -> std::map::HashMap<ast::def_id, V> {
+    return std::map::HashMap::<ast::def_id, V>();
 }
 
 fn block_from_expr(e: @expr) -> blk {
diff --git a/src/libsyntax/attr.rs b/src/libsyntax/attr.rs
index a12233765ca..67a7b6d3101 100644
--- a/src/libsyntax/attr.rs
+++ b/src/libsyntax/attr.rs
@@ -1,7 +1,7 @@
 // Functions dealing with attributes and meta_items
 
 use std::map;
-use std::map::hashmap;
+use std::map::HashMap;
 use either::Either;
 use diagnostic::span_handler;
 use ast_util::{spanned, dummy_spanned};
diff --git a/src/libsyntax/ext/auto_serialize.rs b/src/libsyntax/ext/auto_serialize.rs
index cd26dc58e73..1dc8cee6ac9 100644
--- a/src/libsyntax/ext/auto_serialize.rs
+++ b/src/libsyntax/ext/auto_serialize.rs
@@ -72,7 +72,7 @@ node twice.
 use base::*;
 use codemap::span;
 use std::map;
-use std::map::hashmap;
+use std::map::HashMap;
 
 export expand;
 
@@ -84,8 +84,8 @@ mod syntax {
     export parse;
 }
 
-type ser_tps_map = map::hashmap<ast::ident, fn@(@ast::expr) -> ~[@ast::stmt]>;
-type deser_tps_map = map::hashmap<ast::ident, fn@() -> @ast::expr>;
+type ser_tps_map = map::HashMap<ast::ident, fn@(@ast::expr) -> ~[@ast::stmt]>;
+type deser_tps_map = map::HashMap<ast::ident, fn@() -> @ast::expr>;
 
 fn expand(cx: ext_ctxt,
           span: span,
diff --git a/src/libsyntax/ext/base.rs b/src/libsyntax/ext/base.rs
index d4d5d2b3b22..e1114ce8e2a 100644
--- a/src/libsyntax/ext/base.rs
+++ b/src/libsyntax/ext/base.rs
@@ -1,4 +1,4 @@
-use std::map::hashmap;
+use std::map::HashMap;
 use parse::parser;
 use diagnostic::span_handler;
 use codemap::{codemap, span, expn_info, expanded_from};
@@ -65,7 +65,7 @@ enum syntax_extension {
 
 // A temporary hard-coded map of methods for expanding syntax extension
 // AST nodes into full ASTs
-fn syntax_expander_table() -> hashmap<~str, syntax_extension> {
+fn syntax_expander_table() -> HashMap<~str, syntax_extension> {
     fn builtin(f: syntax_expander_) -> syntax_extension
         {normal({expander: f, span: None})}
     fn builtin_expr_tt(f: syntax_expander_tt_) -> syntax_extension {
diff --git a/src/libsyntax/ext/expand.rs b/src/libsyntax/ext/expand.rs
index 4558d0a1872..ffe86c94a24 100644
--- a/src/libsyntax/ext/expand.rs
+++ b/src/libsyntax/ext/expand.rs
@@ -1,4 +1,4 @@
-use std::map::hashmap;
+use std::map::HashMap;
 
 use ast::{crate, expr_, expr_mac, mac_invoc, mac_invoc_tt,
              tt_delim, tt_tok, item_mac};
@@ -10,7 +10,7 @@ use parse::{parser, parse_expr_from_source_str, new_parser_from_tt};
 
 use codemap::{span, expanded_from};
 
-fn expand_expr(exts: hashmap<~str, syntax_extension>, cx: ext_ctxt,
+fn expand_expr(exts: HashMap<~str, syntax_extension>, cx: ext_ctxt,
                e: expr_, s: span, fld: ast_fold,
                orig: fn@(expr_, span, ast_fold) -> (expr_, span))
     -> (expr_, span)
@@ -132,7 +132,7 @@ fn expand_expr(exts: hashmap<~str, syntax_extension>, cx: ext_ctxt,
 //
 // NB: there is some redundancy between this and expand_item, below, and
 // they might benefit from some amount of semantic and language-UI merger.
-fn expand_mod_items(exts: hashmap<~str, syntax_extension>, cx: ext_ctxt,
+fn expand_mod_items(exts: HashMap<~str, syntax_extension>, cx: ext_ctxt,
                     module_: ast::_mod, fld: ast_fold,
                     orig: fn@(ast::_mod, ast_fold) -> ast::_mod)
     -> ast::_mod
@@ -165,7 +165,7 @@ fn expand_mod_items(exts: hashmap<~str, syntax_extension>, cx: ext_ctxt,
 
 
 // When we enter a module, record it, for the sake of `module!`
-fn expand_item(exts: hashmap<~str, syntax_extension>,
+fn expand_item(exts: HashMap<~str, syntax_extension>,
                cx: ext_ctxt, &&it: @ast::item, fld: ast_fold,
                orig: fn@(&&@ast::item, ast_fold) -> Option<@ast::item>)
     -> Option<@ast::item>
@@ -193,7 +193,7 @@ fn expand_item(exts: hashmap<~str, syntax_extension>,
 
 // Support for item-position macro invocations, exactly the same
 // logic as for expression-position macro invocations.
-fn expand_item_mac(exts: hashmap<~str, syntax_extension>,
+fn expand_item_mac(exts: HashMap<~str, syntax_extension>,
                    cx: ext_ctxt, &&it: @ast::item,
                    fld: ast_fold) -> Option<@ast::item> {
     match it.node {
diff --git a/src/libsyntax/ext/simplext.rs b/src/libsyntax/ext/simplext.rs
index c6ddc449b20..56fbb3bb074 100644
--- a/src/libsyntax/ext/simplext.rs
+++ b/src/libsyntax/ext/simplext.rs
@@ -1,5 +1,5 @@
 use codemap::span;
-use std::map::{hashmap, str_hash, uint_hash};
+use std::map::{HashMap, str_hash, uint_hash};
 use dvec::DVec;
 
 use base::*;
@@ -123,9 +123,9 @@ fn compose_sels(s1: selector, s2: selector) -> selector {
 
 
 type binders =
-    {real_binders: hashmap<ident, selector>,
+    {real_binders: HashMap<ident, selector>,
      literal_ast_matchers: DVec<selector>};
-type bindings = hashmap<ident, arb_depth<matchable>>;
+type bindings = HashMap<ident, arb_depth<matchable>>;
 
 fn acumm_bindings(_cx: ext_ctxt, _b_dest: bindings, _b_src: bindings) { }
 
@@ -237,9 +237,9 @@ fn follow_for_trans(cx: ext_ctxt, mmaybe: Option<arb_depth<matchable>>,
 
 /* helper for transcribe_exprs: what vars from `b` occur in `e`? */
 fn free_vars(b: bindings, e: @expr, it: fn(ident)) {
-    let idents: hashmap<ident, ()> = uint_hash::<()>();
+    let idents: HashMap<ident, ()> = uint_hash::<()>();
     fn mark_ident(&&i: ident, _fld: ast_fold, b: bindings,
-                  idents: hashmap<ident, ()>) -> ident {
+                  idents: HashMap<ident, ()>) -> ident {
         if b.contains_key(i) { idents.insert(i, ()); }
         return i;
     }
diff --git a/src/libsyntax/ext/tt/macro_parser.rs b/src/libsyntax/ext/tt/macro_parser.rs
index 22f588f98c5..f32c23c936f 100644
--- a/src/libsyntax/ext/tt/macro_parser.rs
+++ b/src/libsyntax/ext/tt/macro_parser.rs
@@ -10,7 +10,7 @@ use parse::parse_sess;
 use dvec::DVec;
 use ast::{matcher, match_tok, match_seq, match_nonterminal, ident};
 use ast_util::mk_sp;
-use std::map::{hashmap, uint_hash};
+use std::map::{HashMap, uint_hash};
 
 /* This is an Earley-like parser, without support for in-grammar nonterminals,
 only by calling out to the main rust parser for named nonterminals (which it
@@ -168,9 +168,9 @@ enum named_match {
 type earley_item = matcher_pos;
 
 fn nameize(p_s: parse_sess, ms: ~[matcher], res: ~[@named_match])
-    -> hashmap<ident,@named_match> {
+    -> HashMap<ident,@named_match> {
     fn n_rec(p_s: parse_sess, m: matcher, res: ~[@named_match],
-             ret_val: hashmap<ident, @named_match>) {
+             ret_val: HashMap<ident, @named_match>) {
         match m {
           {node: match_tok(_), span: _} => (),
           {node: match_seq(more_ms, _, _, _, _), span: _} => {
@@ -191,13 +191,13 @@ fn nameize(p_s: parse_sess, ms: ~[matcher], res: ~[@named_match])
 }
 
 enum parse_result {
-    success(hashmap<ident, @named_match>),
+    success(HashMap<ident, @named_match>),
     failure(codemap::span, ~str),
     error(codemap::span, ~str)
 }
 
 fn parse_or_else(sess: parse_sess, cfg: ast::crate_cfg, rdr: reader,
-                 ms: ~[matcher]) -> hashmap<ident, @named_match> {
+                 ms: ~[matcher]) -> HashMap<ident, @named_match> {
     match parse(sess, cfg, rdr, ms) {
       success(m) => m,
       failure(sp, str) => sess.span_diagnostic.span_fatal(sp, str),
diff --git a/src/libsyntax/ext/tt/macro_rules.rs b/src/libsyntax/ext/tt/macro_rules.rs
index 30b5d479f05..ebb62293cc5 100644
--- a/src/libsyntax/ext/tt/macro_rules.rs
+++ b/src/libsyntax/ext/tt/macro_rules.rs
@@ -7,7 +7,7 @@ use parse::token::{FAT_ARROW, SEMI, LBRACE, RBRACE, nt_matchers, nt_tt};
 use parse::parser::{parser, SOURCE_FILE};
 use macro_parser::{parse, parse_or_else, success, failure, named_match,
                       matched_seq, matched_nonterminal, error};
-use std::map::hashmap;
+use std::map::HashMap;
 use parse::token::special_idents;
 
 fn add_new_extension(cx: ext_ctxt, sp: span, name: ident,
diff --git a/src/libsyntax/ext/tt/transcribe.rs b/src/libsyntax/ext/tt/transcribe.rs
index 01e2328c85a..f7c7475bfc9 100644
--- a/src/libsyntax/ext/tt/transcribe.rs
+++ b/src/libsyntax/ext/tt/transcribe.rs
@@ -4,7 +4,7 @@ use macro_parser::{named_match, matched_seq, matched_nonterminal};
 use codemap::span;
 use parse::token::{EOF, INTERPOLATED, IDENT, token, nt_ident,
                       ident_interner};
-use std::map::{hashmap, box_str_hash};
+use std::map::{HashMap, box_str_hash};
 
 export tt_reader,  new_tt_reader, dup_tt_reader, tt_next_token;
 
@@ -28,7 +28,7 @@ type tt_reader = @{
     interner: ident_interner,
     mut cur: tt_frame,
     /* for MBE-style macro transcription */
-    interpolations: std::map::hashmap<ident, @named_match>,
+    interpolations: std::map::HashMap<ident, @named_match>,
     mut repeat_idx: ~[mut uint],
     mut repeat_len: ~[uint],
     /* cached: */
@@ -40,7 +40,7 @@ type tt_reader = @{
  *  `src` contains no `tt_seq`s and `tt_nonterminal`s, `interp` can (and
  *  should) be none. */
 fn new_tt_reader(sp_diag: span_handler, itr: ident_interner,
-                 interp: Option<std::map::hashmap<ident,@named_match>>,
+                 interp: Option<std::map::HashMap<ident,@named_match>>,
                  src: ~[ast::token_tree])
     -> tt_reader {
     let r = @{sp_diag: sp_diag, interner: itr,
diff --git a/src/libsyntax/parse/common.rs b/src/libsyntax/parse/common.rs
index c2ed8a7d9d6..d71d95fd63f 100644
--- a/src/libsyntax/parse/common.rs
+++ b/src/libsyntax/parse/common.rs
@@ -1,4 +1,4 @@
-use std::map::{hashmap};
+use std::map::{HashMap};
 use ast_util::spanned;
 use parser::parser;
 use lexer::reader;
diff --git a/src/libsyntax/parse/parser.rs b/src/libsyntax/parse/parser.rs
index 512a5e6459e..e597d33a836 100644
--- a/src/libsyntax/parse/parser.rs
+++ b/src/libsyntax/parse/parser.rs
@@ -2,7 +2,7 @@ use print::pprust::expr_to_str;
 
 use result::Result;
 use either::{Either, Left, Right};
-use std::map::{hashmap, str_hash};
+use std::map::{HashMap, str_hash};
 use token::{can_begin_expr, is_ident, is_ident_or_path, is_plain_ident,
                INTERPOLATED};
 use codemap::{span,fss_none};
@@ -216,7 +216,7 @@ fn parser(sess: parse_sess, cfg: ast::crate_cfg,
         keywords: token::keyword_table(),
         restricted_keywords: token::restricted_keyword_table(),
         strict_keywords: token::strict_keyword_table(),
-        obsolete_set: std::map::hashmap(),
+        obsolete_set: std::map::HashMap(),
     }
 }
 
@@ -234,12 +234,12 @@ struct parser {
     mut quote_depth: uint, // not (yet) related to the quasiquoter
     reader: reader,
     interner: interner<@~str>,
-    keywords: hashmap<~str, ()>,
-    restricted_keywords: hashmap<~str, ()>,
-    strict_keywords: hashmap<~str, ()>,
+    keywords: HashMap<~str, ()>,
+    restricted_keywords: HashMap<~str, ()>,
+    strict_keywords: HashMap<~str, ()>,
     /// The set of seen errors about obsolete syntax. Used to suppress
     /// extra detail when the same error is seen twice
-    obsolete_set: hashmap<ObsoleteSyntax, ()>,
+    obsolete_set: HashMap<ObsoleteSyntax, ()>,
 
     drop {} /* do not copy the parser; its state is tied to outside state */
 }
diff --git a/src/libsyntax/parse/token.rs b/src/libsyntax/parse/token.rs
index 6e82e6d11b8..a96b2be6c09 100644
--- a/src/libsyntax/parse/token.rs
+++ b/src/libsyntax/parse/token.rs
@@ -1,6 +1,6 @@
 use util::interner;
 use util::interner::interner;
-use std::map::{hashmap, str_hash};
+use std::map::{HashMap, str_hash};
 use std::serialization::{serializer,
                             deserializer,
                             serialize_uint,
@@ -368,7 +368,7 @@ fn mk_fake_ident_interner() -> ident_interner {
  * that might otherwise contain _value identifiers_.  Strict keywords may not
  * appear as identifiers.
  */
-fn keyword_table() -> hashmap<~str, ()> {
+fn keyword_table() -> HashMap<~str, ()> {
     let keywords = str_hash();
     for contextual_keyword_table().each_key |word| {
         keywords.insert(word, ());
@@ -383,7 +383,7 @@ fn keyword_table() -> hashmap<~str, ()> {
 }
 
 /// Keywords that may be used as identifiers
-fn contextual_keyword_table() -> hashmap<~str, ()> {
+fn contextual_keyword_table() -> HashMap<~str, ()> {
     let words = str_hash();
     let keys = ~[
         ~"self", ~"static",
@@ -408,7 +408,7 @@ fn contextual_keyword_table() -> hashmap<~str, ()> {
  * * `true` or `false` as identifiers would always be shadowed by
  *   the boolean constants
  */
-fn restricted_keyword_table() -> hashmap<~str, ()> {
+fn restricted_keyword_table() -> HashMap<~str, ()> {
     let words = str_hash();
     let keys = ~[
         ~"const", ~"copy",
@@ -426,7 +426,7 @@ fn restricted_keyword_table() -> hashmap<~str, ()> {
 }
 
 /// Full keywords. May not appear anywhere else.
-fn strict_keyword_table() -> hashmap<~str, ()> {
+fn strict_keyword_table() -> HashMap<~str, ()> {
     let words = str_hash();
     let keys = ~[
         ~"as", ~"assert",
diff --git a/src/libsyntax/util/interner.rs b/src/libsyntax/util/interner.rs
index ac2af21d087..7e42919f724 100644
--- a/src/libsyntax/util/interner.rs
+++ b/src/libsyntax/util/interner.rs
@@ -2,18 +2,18 @@
 // allows bidirectional lookup; i.e. given a value, one can easily find the
 // type, and vice versa.
 use std::map;
-use std::map::hashmap;
+use std::map::HashMap;
 use dvec::DVec;
 use cmp::Eq;
 use hash::Hash;
 use to_bytes::IterBytes;
 
 type hash_interner<T: Const> =
-    {map: hashmap<T, uint>,
+    {map: HashMap<T, uint>,
      vect: DVec<T>};
 
 fn mk<T:Eq IterBytes Hash Const Copy>() -> interner<T> {
-    let m = map::hashmap::<T, uint>();
+    let m = map::HashMap::<T, uint>();
     let hi: hash_interner<T> =
         {map: m, vect: DVec()};
     return hi as interner::<T>;