summary refs log tree commit diff
path: root/src/libstd/collections
diff options
context:
space:
mode:
authorBarosl Lee <vcs@barosl.com>2014-11-12 03:36:09 +0900
committerBarosl Lee <vcs@barosl.com>2014-11-12 03:36:09 +0900
commit8bf77fa786aae4993fa923f0826529bfb9ce1166 (patch)
treea7ac9d644b4e116aa78ac337c749f73ebdcdadf3 /src/libstd/collections
parent5d29209bda553e4d23a8b499d2ceb8db5c4f8be5 (diff)
downloadrust-8bf77fa786aae4993fa923f0826529bfb9ce1166.tar.gz
rust-8bf77fa786aae4993fa923f0826529bfb9ce1166.zip
Fix remaining documentation to reflect fail!() -> panic!()
Throughout the docs, "failure" was replaced with "panics" if it means a
task panic. Otherwise, it remained as is, or changed to "errors" to
clearly differentiate it from a task panic.
Diffstat (limited to 'src/libstd/collections')
-rw-r--r--src/libstd/collections/hash/map.rs4
-rw-r--r--src/libstd/collections/hash/table.rs4
2 files changed, 4 insertions, 4 deletions
diff --git a/src/libstd/collections/hash/map.rs b/src/libstd/collections/hash/map.rs
index f55ce9ba462..b7473e7bd2c 100644
--- a/src/libstd/collections/hash/map.rs
+++ b/src/libstd/collections/hash/map.rs
@@ -1238,9 +1238,9 @@ impl<K: Eq + Hash<S>, V: Clone, S, H: Hasher<S>> HashMap<K, V, H> {
 
     /// Return a copy of the value corresponding to the key.
     ///
-    /// # Failure
+    /// # Panics
     ///
-    /// Fails if the key is not present.
+    /// Panics if the key is not present.
     ///
     /// # Example
     ///
diff --git a/src/libstd/collections/hash/table.rs b/src/libstd/collections/hash/table.rs
index fd964cdf02c..275117a896a 100644
--- a/src/libstd/collections/hash/table.rs
+++ b/src/libstd/collections/hash/table.rs
@@ -512,9 +512,9 @@ impl<K, V, M: Deref<RawTable<K, V>>> GapThenFull<K, V, M> {
 /// Rounds up to a multiple of a power of two. Returns the closest multiple
 /// of `target_alignment` that is higher or equal to `unrounded`.
 ///
-/// # Failure
+/// # Panics
 ///
-/// Fails if `target_alignment` is not a power of two.
+/// Panics if `target_alignment` is not a power of two.
 fn round_up_to_next(unrounded: uint, target_alignment: uint) -> uint {
     assert!(is_power_of_two(target_alignment));
     (unrounded + target_alignment - 1) & !(target_alignment - 1)