about summary refs log tree commit diff
path: root/src/libstd/result.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/libstd/result.rs')
-rw-r--r--src/libstd/result.rs19
1 files changed, 1 insertions, 18 deletions
diff --git a/src/libstd/result.rs b/src/libstd/result.rs
index 39e8b6ad6c1..3f09351ead6 100644
--- a/src/libstd/result.rs
+++ b/src/libstd/result.rs
@@ -12,14 +12,11 @@
 
 use clone::Clone;
 use cmp::Eq;
-use fmt;
 use iter::{Iterator, FromIterator};
 use option::{None, Option, Some};
-use str::OwnedStr;
-use to_str::ToStr;
 
 /// `Result` is a type that represents either success (`Ok`) or failure (`Err`).
-#[deriving(Clone, DeepClone, Eq, Ord, TotalEq, TotalOrd, ToStr)]
+#[deriving(Clone, DeepClone, Eq, Ord, TotalEq, TotalOrd, Show)]
 #[must_use]
 pub enum Result<T, E> {
     /// Contains the success value
@@ -203,20 +200,6 @@ impl<T, E> Result<T, E> {
 }
 
 /////////////////////////////////////////////////////////////////////////////
-// Trait implementations
-/////////////////////////////////////////////////////////////////////////////
-
-impl<T: fmt::Show, E: fmt::Show> fmt::Show for Result<T, E> {
-    #[inline]
-    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
-        match *self {
-            Ok(ref t) => write!(f.buf, "Ok({})", *t),
-            Err(ref e) => write!(f.buf, "Err({})", *e)
-        }
-    }
-}
-
-/////////////////////////////////////////////////////////////////////////////
 // Free functions
 /////////////////////////////////////////////////////////////////////////////