diff --git a/src/util/parse.rs b/src/util/parse.rs index 30850d38f..6d7347fe7 100644 --- a/src/util/parse.rs +++ b/src/util/parse.rs @@ -157,7 +157,8 @@ pub fn symbol_to_id(token: &str, tokenlist: TokenList) -> Result { // amount_vec.push(digit); // } // -// Ok(amount_vec.drain()) +// let amount: u64 = amount_vec.drain(); +// Ok(amount) //} mod tests { @@ -185,6 +186,7 @@ mod tests { }; println!("Removed decimal point: {}", amount); + // only digits should remain: for c in amount.chars() { if c.is_digit(RADIX) == false { @@ -222,6 +224,7 @@ mod tests { for i in amount.chars() { let digit = i.to_digit(RADIX).unwrap(); println!("Converted to integer: {}", digit); + let u = u64::from(digit); } }