diff options
| author | Huon Wilson <dbau.pp+github@gmail.com> | 2014-02-23 21:29:35 +1100 |
|---|---|---|
| committer | Huon Wilson <dbau.pp+github@gmail.com> | 2014-02-24 07:44:10 +1100 |
| commit | efaf4db24c92e119e26dc575ffd6bfd3b91fb87d (patch) | |
| tree | e735230061b0c480550fdaad749a998bc48df78d /src/libextra | |
| parent | 5444da54fd32b705eec28112e309f63b704e3f8c (diff) | |
| download | rust-efaf4db24c92e119e26dc575ffd6bfd3b91fb87d.tar.gz rust-efaf4db24c92e119e26dc575ffd6bfd3b91fb87d.zip | |
Transition to new `Hash`, removing IterBytes and std::to_bytes.
Diffstat (limited to 'src/libextra')
| -rw-r--r-- | src/libextra/stats.rs | 2 | ||||
| -rw-r--r-- | src/libextra/url.rs | 14 |
2 files changed, 8 insertions, 8 deletions
diff --git a/src/libextra/stats.rs b/src/libextra/stats.rs index d791e1a2988..2450e22fc10 100644 --- a/src/libextra/stats.rs +++ b/src/libextra/stats.rs @@ -11,7 +11,7 @@ #[allow(missing_doc)]; use std::cmp; -use std::hash_old::Hash; +use std::hash::Hash; use std::io; use std::mem; use std::num; diff --git a/src/libextra/url.rs b/src/libextra/url.rs index 6353e7e1159..41d6d95c6bb 100644 --- a/src/libextra/url.rs +++ b/src/libextra/url.rs @@ -15,7 +15,7 @@ use std::io::BufReader; use std::cmp::Eq; use collections::HashMap; -use std::to_bytes; +use std::hash::{Hash, sip}; use std::uint; /// A Uniform Resource Locator (URL). A URL is a form of URI (Uniform Resource @@ -855,15 +855,15 @@ impl ToStr for Path { } } -impl IterBytes for Url { - fn iter_bytes(&self, lsb0: bool, f: to_bytes::Cb) -> bool { - self.to_str().iter_bytes(lsb0, f) +impl Hash for Url { + fn hash(&self, s: &mut sip::SipState) { + self.to_str().hash(s) } } -impl IterBytes for Path { - fn iter_bytes(&self, lsb0: bool, f: to_bytes::Cb) -> bool { - self.to_str().iter_bytes(lsb0, f) +impl Hash for Path { + fn hash(&self, s: &mut sip::SipState) { + self.to_str().hash(s) } } |
