1
0
Fork 0

rpn(1): re-fixed arg parsing

This commit is contained in:
Emma Tebibyte 2024-02-02 19:17:00 -07:00
parent 6f98fdd1d4
commit 4993c53080
Signed by untrusted user: emma
GPG Key ID: 06FA419A1698C270
1 changed files with 1 additions and 2 deletions

View File

@ -137,7 +137,7 @@ fn eval(
// Split the input into tokens.
let mut toks: VecDeque<CalcType> = input
.split(' ')
.split_whitespace()
.rev()
.map(|t| CalcType::from(t))
.collect();
@ -223,7 +223,6 @@ fn main() -> ExitCode {
let input = argv
.iter()
.skip(1)
.rev()
.map(|x| x.to_owned())
.collect::<Vec<String>>()
.join(" ");