about summary refs log tree commit diff
path: root/src/libsyntax/util
diff options
context:
space:
mode:
authorHuon Wilson <dbau.pp+github@gmail.com>2014-02-23 21:29:35 +1100
committerHuon Wilson <dbau.pp+github@gmail.com>2014-02-24 07:44:10 +1100
commitefaf4db24c92e119e26dc575ffd6bfd3b91fb87d (patch)
treee735230061b0c480550fdaad749a998bc48df78d /src/libsyntax/util
parent5444da54fd32b705eec28112e309f63b704e3f8c (diff)
downloadrust-efaf4db24c92e119e26dc575ffd6bfd3b91fb87d.tar.gz
rust-efaf4db24c92e119e26dc575ffd6bfd3b91fb87d.zip
Transition to new `Hash`, removing IterBytes and std::to_bytes.
Diffstat (limited to 'src/libsyntax/util')
-rw-r--r--src/libsyntax/util/interner.rs10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/libsyntax/util/interner.rs b/src/libsyntax/util/interner.rs
index 44b366c9890..fa21924bbb9 100644
--- a/src/libsyntax/util/interner.rs
+++ b/src/libsyntax/util/interner.rs
@@ -18,7 +18,7 @@ use collections::HashMap;
 use std::cast;
 use std::cell::RefCell;
 use std::cmp::Equiv;
-use std::hash_old::Hash;
+use std::hash::Hash;
 use std::rc::Rc;
 
 pub struct Interner<T> {
@@ -27,7 +27,7 @@ pub struct Interner<T> {
 }
 
 // when traits can extend traits, we should extend index<Name,T> to get []
-impl<T:Eq + IterBytes + Hash + Freeze + Clone + 'static> Interner<T> {
+impl<T:Eq + Hash + Freeze + Clone + 'static> Interner<T> {
     pub fn new() -> Interner<T> {
         Interner {
             map: RefCell::new(HashMap::new()),
@@ -75,7 +75,7 @@ impl<T:Eq + IterBytes + Hash + Freeze + Clone + 'static> Interner<T> {
         vect.get().len()
     }
 
-    pub fn find_equiv<Q:Hash + IterBytes + Equiv<T>>(&self, val: &Q)
+    pub fn find_equiv<Q:Hash + Equiv<T>>(&self, val: &Q)
                                               -> Option<Name> {
         let map = self.map.borrow();
         match map.get().find_equiv(val) {
@@ -85,7 +85,7 @@ impl<T:Eq + IterBytes + Hash + Freeze + Clone + 'static> Interner<T> {
     }
 }
 
-#[deriving(Clone, Eq, IterBytes, Ord)]
+#[deriving(Clone, Eq, Hash, Ord)]
 pub struct RcStr {
     priv string: Rc<~str>,
 }
@@ -207,7 +207,7 @@ impl StrInterner {
         vect.get().len()
     }
 
-    pub fn find_equiv<Q:Hash + IterBytes + Equiv<RcStr>>(&self, val: &Q)
+    pub fn find_equiv<Q:Hash + Equiv<RcStr>>(&self, val: &Q)
                                                          -> Option<Name> {
         let map = self.map.borrow();
         match map.get().find_equiv(val) {