about summary refs log tree commit diff
path: root/src/libcollections
diff options
context:
space:
mode:
authorBrian Anderson <banderson@mozilla.com>2014-05-19 11:32:09 -0700
committerAlex Crichton <alex@alexcrichton.com>2014-06-08 21:29:57 -0700
commit50942c7695783875bd2161596036a52755ffb09c (patch)
tree0d8ddd4e8d3a58c33de17eeb966684f6796d4547 /src/libcollections
parent443a1cdf949fad31c5a851be02017d09ce09f318 (diff)
downloadrust-50942c7695783875bd2161596036a52755ffb09c.tar.gz
rust-50942c7695783875bd2161596036a52755ffb09c.zip
core: Rename `container` mod to `collections`. Closes #12543
Also renames the `Container` trait to `Collection`.

[breaking-change]
Diffstat (limited to 'src/libcollections')
-rw-r--r--src/libcollections/bitv.rs2
-rw-r--r--src/libcollections/dlist.rs2
-rw-r--r--src/libcollections/priority_queue.rs2
-rw-r--r--src/libcollections/ringbuf.rs2
-rw-r--r--src/libcollections/smallintmap.rs2
-rw-r--r--src/libcollections/str.rs4
-rw-r--r--src/libcollections/string.rs2
-rw-r--r--src/libcollections/treemap.rs4
-rw-r--r--src/libcollections/trie.rs4
-rw-r--r--src/libcollections/vec.rs2
10 files changed, 13 insertions, 13 deletions
diff --git a/src/libcollections/bitv.rs b/src/libcollections/bitv.rs
index 79e0c2ffea8..ac31fbbf9e4 100644
--- a/src/libcollections/bitv.rs
+++ b/src/libcollections/bitv.rs
@@ -857,7 +857,7 @@ impl<S: hash::Writer> hash::Hash<S> for BitvSet {
     }
 }
 
-impl Container for BitvSet {
+impl Collection for BitvSet {
     #[inline]
     fn len(&self) -> uint { self.size }
 }
diff --git a/src/libcollections/dlist.rs b/src/libcollections/dlist.rs
index 9d0e8e83698..f71cc7401c5 100644
--- a/src/libcollections/dlist.rs
+++ b/src/libcollections/dlist.rs
@@ -125,7 +125,7 @@ fn link_with_prev<T>(mut next: Box<Node<T>>, prev: Rawlink<Node<T>>)
     Some(next)
 }
 
-impl<T> Container for DList<T> {
+impl<T> Collection for DList<T> {
     /// O(1)
     #[inline]
     fn is_empty(&self) -> bool {
diff --git a/src/libcollections/priority_queue.rs b/src/libcollections/priority_queue.rs
index 34d6bbbb665..f10c6f230ae 100644
--- a/src/libcollections/priority_queue.rs
+++ b/src/libcollections/priority_queue.rs
@@ -26,7 +26,7 @@ pub struct PriorityQueue<T> {
     data: Vec<T>,
 }
 
-impl<T: Ord> Container for PriorityQueue<T> {
+impl<T: Ord> Collection for PriorityQueue<T> {
     /// Returns the length of the queue
     fn len(&self) -> uint { self.data.len() }
 }
diff --git a/src/libcollections/ringbuf.rs b/src/libcollections/ringbuf.rs
index ce4195789fa..5708dfaf915 100644
--- a/src/libcollections/ringbuf.rs
+++ b/src/libcollections/ringbuf.rs
@@ -33,7 +33,7 @@ pub struct RingBuf<T> {
     elts: Vec<Option<T>>
 }
 
-impl<T> Container for RingBuf<T> {
+impl<T> Collection for RingBuf<T> {
     /// Return the number of elements in the RingBuf
     fn len(&self) -> uint { self.nelts }
 }
diff --git a/src/libcollections/smallintmap.rs b/src/libcollections/smallintmap.rs
index 45584dd4b28..c61f518caa4 100644
--- a/src/libcollections/smallintmap.rs
+++ b/src/libcollections/smallintmap.rs
@@ -29,7 +29,7 @@ pub struct SmallIntMap<T> {
     v: Vec<Option<T>>,
 }
 
-impl<V> Container for SmallIntMap<V> {
+impl<V> Collection for SmallIntMap<V> {
     /// Return the number of elements in the map
     fn len(&self) -> uint {
         self.v.iter().filter(|elt| elt.is_some()).count()
diff --git a/src/libcollections/str.rs b/src/libcollections/str.rs
index 5fd133b450f..102d9c3abde 100644
--- a/src/libcollections/str.rs
+++ b/src/libcollections/str.rs
@@ -610,7 +610,7 @@ impl<'a> StrAllocating for MaybeOwned<'a> {
     }
 }
 
-impl<'a> Container for MaybeOwned<'a> {
+impl<'a> Collection for MaybeOwned<'a> {
     #[inline]
     fn len(&self) -> uint { self.as_slice().len() }
 }
@@ -2036,7 +2036,7 @@ mod tests {
 
     #[test]
     fn test_str_container() {
-        fn sum_len<S: Container>(v: &[S]) -> uint {
+        fn sum_len<S: Collection>(v: &[S]) -> uint {
             v.iter().map(|x| x.len()).sum()
         }
 
diff --git a/src/libcollections/string.rs b/src/libcollections/string.rs
index bd39c74aa84..1c1d4b98592 100644
--- a/src/libcollections/string.rs
+++ b/src/libcollections/string.rs
@@ -279,7 +279,7 @@ impl String {
     }
 }
 
-impl Container for String {
+impl Collection for String {
     #[inline]
     fn len(&self) -> uint {
         self.vec.len()
diff --git a/src/libcollections/treemap.rs b/src/libcollections/treemap.rs
index def1c353bc1..8d472282a68 100644
--- a/src/libcollections/treemap.rs
+++ b/src/libcollections/treemap.rs
@@ -86,7 +86,7 @@ impl<K: Ord + Show, V: Show> Show for TreeMap<K, V> {
     }
 }
 
-impl<K: Ord, V> Container for TreeMap<K, V> {
+impl<K: Ord, V> Collection for TreeMap<K, V> {
     fn len(&self) -> uint { self.length }
 }
 
@@ -579,7 +579,7 @@ impl<T: Ord + Show> Show for TreeSet<T> {
     }
 }
 
-impl<T: Ord> Container for TreeSet<T> {
+impl<T: Ord> Collection for TreeSet<T> {
     #[inline]
     fn len(&self) -> uint { self.map.len() }
 }
diff --git a/src/libcollections/trie.rs b/src/libcollections/trie.rs
index c15a6e9e5bf..1c6b7ed9333 100644
--- a/src/libcollections/trie.rs
+++ b/src/libcollections/trie.rs
@@ -38,7 +38,7 @@ pub struct TrieMap<T> {
     length: uint
 }
 
-impl<T> Container for TrieMap<T> {
+impl<T> Collection for TrieMap<T> {
     /// Return the number of elements in the map
     #[inline]
     fn len(&self) -> uint { self.length }
@@ -285,7 +285,7 @@ pub struct TrieSet {
     map: TrieMap<()>
 }
 
-impl Container for TrieSet {
+impl Collection for TrieSet {
     /// Return the number of elements in the set
     #[inline]
     fn len(&self) -> uint { self.map.len() }
diff --git a/src/libcollections/vec.rs b/src/libcollections/vec.rs
index 37546f64d5f..3d0182acc7e 100644
--- a/src/libcollections/vec.rs
+++ b/src/libcollections/vec.rs
@@ -393,7 +393,7 @@ impl<T: Ord> Ord for Vec<T> {
     }
 }
 
-impl<T> Container for Vec<T> {
+impl<T> Collection for Vec<T> {
     #[inline]
     fn len(&self) -> uint {
         self.len