about summary refs log tree commit diff
path: root/src/libstd/treemap.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/libstd/treemap.rs')
-rw-r--r--src/libstd/treemap.rs12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/libstd/treemap.rs b/src/libstd/treemap.rs
index b77037ba3ad..fccf58ddb6f 100644
--- a/src/libstd/treemap.rs
+++ b/src/libstd/treemap.rs
@@ -152,6 +152,12 @@ impl<K: TotalOrd, V> Map<K, V> for TreeMap<K, V> {
         }
     }
 
+    /// Return a mutable reference to the value corresponding to the key
+    #[inline(always)]
+    fn find_mut(&mut self, key: &K) -> Option<&'self mut V> {
+        find_mut(&mut self.root, key)
+    }
+
     /// Insert a key-value pair into the map. An existing value for a
     /// key is replaced by the new value. Return true if the key did
     /// not already exist in the map.
@@ -189,12 +195,6 @@ pub impl<K: TotalOrd, V> TreeMap<K, V> {
     fn iter(&self) -> TreeMapIterator<'self, K, V> {
         TreeMapIterator{stack: ~[], node: &self.root}
     }
-
-    /// Return a mutable reference to the value corresponding to the key
-    #[inline(always)]
-    fn find_mut(&mut self, key: &K) -> Option<&'self mut V> {
-        find_mut(&mut self.root, key)
-    }
 }
 
 /// Lazy forward iterator over a map