diff options
| author | Brian Anderson <banderson@mozilla.com> | 2012-08-14 16:54:13 -0700 |
|---|---|---|
| committer | Brian Anderson <banderson@mozilla.com> | 2012-08-15 14:14:20 -0700 |
| commit | 74c69e1053188d92b86bc8b28cbf1af87d31ea2d (patch) | |
| tree | 8c07fc440e572eb59787705a9dd11fcd789430e0 /src/libcore/result.rs | |
| parent | 8be0f665bcda9f5e4077d0be6ebc6aa382e72319 (diff) | |
Convert more core types to camel case
Diffstat (limited to 'src/libcore/result.rs')
| -rw-r--r-- | src/libcore/result.rs | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/libcore/result.rs b/src/libcore/result.rs index 762191842b8..341d28e67e8 100644 --- a/src/libcore/result.rs +++ b/src/libcore/result.rs @@ -1,6 +1,6 @@ //! A type representing either success or failure -import either::either; +import either::Either; /// The result type enum result<T, U> { @@ -59,10 +59,10 @@ pure fn is_err<T, U>(res: result<T, U>) -> bool { * `ok` result variants are converted to `either::right` variants, `err` * result variants are converted to `either::left`. */ -pure fn to_either<T: copy, U: copy>(res: result<U, T>) -> either<T, U> { +pure fn to_either<T: copy, U: copy>(res: result<U, T>) -> Either<T, U> { match res { - ok(res) => either::right(res), - err(fail_) => either::left(fail_) + ok(res) => either::Right(res), + err(fail_) => either::Left(fail_) } } |
