about summary refs log tree commit diff
path: root/src/libcore/either.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/libcore/either.rs')
-rw-r--r--src/libcore/either.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/libcore/either.rs b/src/libcore/either.rs
index c4f07db6621..6b327b919e5 100644
--- a/src/libcore/either.rs
+++ b/src/libcore/either.rs
@@ -136,7 +136,7 @@ pub pure fn unwrap_left<T,U>(eith: Either<T,U>) -> T {
     //! Retrieves the value in the left branch. Fails if the either is Right.
 
     match move eith {
-        Left(move x) => move x, Right(_) => fail ~"either::unwrap_left Right"
+        Left(move x) => move x, Right(_) => die!(~"either::unwrap_left Right")
     }
 }
 
@@ -145,7 +145,7 @@ pub pure fn unwrap_right<T,U>(eith: Either<T,U>) -> U {
     //! Retrieves the value in the right branch. Fails if the either is Left.
 
     match move eith {
-        Right(move x) => move x, Left(_) => fail ~"either::unwrap_right Left"
+        Right(move x) => move x, Left(_) => die!(~"either::unwrap_right Left")
     }
 }