Concise-ify code

This commit is contained in:
greg 2017-09-11 02:07:48 -07:00
parent 741e5f7f9b
commit 0dabbc700b
1 changed files with 2 additions and 3 deletions

View File

@ -451,11 +451,10 @@ impl Parser {
use self::TokenType::*; use self::TokenType::*;
let mut ds = String::new(); let mut ds = String::new();
loop { loop {
let xxx = self.next(); match self.next() {
match xxx {
Underscore => continue, Underscore => continue,
DigitGroup(ref s) => ds.push_str(s), DigitGroup(ref s) => ds.push_str(s),
x => break, _ => break,
} }
} }
Ok(ds) Ok(ds)