diff options
| author | Alex Crichton <alex@alexcrichton.com> | 2013-12-25 21:55:05 -0800 |
|---|---|---|
| committer | Alex Crichton <alex@alexcrichton.com> | 2014-01-03 10:25:23 -0800 |
| commit | 4bea679dbe3ba98049ac700d84ad48271753ce40 (patch) | |
| tree | 59e197f0318733d8034b2e516d237d802f8e3fa4 /src/libstd/fmt/mod.rs | |
| parent | 5ff7b283731b795930d1e6782ae1639c83595e91 (diff) | |
Remove std::either
Diffstat (limited to 'src/libstd/fmt/mod.rs')
| -rw-r--r-- | src/libstd/fmt/mod.rs | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/src/libstd/fmt/mod.rs b/src/libstd/fmt/mod.rs index cd9c0f5d2b7..53eaf17c7f8 100644 --- a/src/libstd/fmt/mod.rs +++ b/src/libstd/fmt/mod.rs @@ -757,7 +757,7 @@ impl<'a> Formatter<'a> { // offsetted value for s in selectors.iter() { match s.selector { - Right(val) if value == val => { + rt::Literal(val) if value == val => { return self.runplural(value, s.result); } _ => {} @@ -769,17 +769,17 @@ impl<'a> Formatter<'a> { let value = value - match offset { Some(i) => i, None => 0 }; for s in selectors.iter() { let run = match s.selector { - Left(parse::Zero) => value == 0, - Left(parse::One) => value == 1, - Left(parse::Two) => value == 2, + rt::Keyword(parse::Zero) => value == 0, + rt::Keyword(parse::One) => value == 1, + rt::Keyword(parse::Two) => value == 2, // XXX: Few/Many should have a user-specified boundary // One possible option would be in the function // pointer of the 'arg: Argument' struct. - Left(parse::Few) => value < 8, - Left(parse::Many) => value >= 8, + rt::Keyword(parse::Few) => value < 8, + rt::Keyword(parse::Many) => value >= 8, - Right(..) => false + rt::Literal(..) => false }; if run { return self.runplural(value, s.result); |
