diff options
author | Akshay <[email protected]> | 2022-04-05 14:48:19 +0100 |
---|---|---|
committer | Akshay <[email protected]> | 2022-04-05 14:48:19 +0100 |
commit | 2886114cf60b56cb724d7ec9420d0d5eb60e7fa0 (patch) | |
tree | 71199307cfb31b8f565343b6ed38dc644787971c /src | |
parent | 9fa2823b3916184dbfbb9c704ab34ae79c0c1038 (diff) |
bump to v0.3.0
Diffstat (limited to 'src')
-rw-r--r-- | src/parse.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/parse.rs b/src/parse.rs index aa8bd4b..74b9841 100644 --- a/src/parse.rs +++ b/src/parse.rs | |||
@@ -78,12 +78,12 @@ pub fn eval_postfix(postfixed: Vec<Token>) -> Result<f64, CalcError> { | |||
78 | num_stack.push(op.operate(n1, n2)?); | 78 | num_stack.push(op.operate(n1, n2)?); |
79 | } else { | 79 | } else { |
80 | return Err(CalcError::Parser( | 80 | return Err(CalcError::Parser( |
81 | "Too many operators, Too little operands".to_string(), | 81 | "Too many operators, too few operands".to_string(), |
82 | )); | 82 | )); |
83 | } | 83 | } |
84 | } else { | 84 | } else { |
85 | return Err(CalcError::Parser( | 85 | return Err(CalcError::Parser( |
86 | "Too many operators, Too little operands".to_string(), | 86 | "Too many operators, too few operands".to_string(), |
87 | )); | 87 | )); |
88 | } | 88 | } |
89 | } | 89 | } |
@@ -99,7 +99,7 @@ pub fn eval_postfix(postfixed: Vec<Token>) -> Result<f64, CalcError> { | |||
99 | Ok(num_stack.pop().unwrap()) | 99 | Ok(num_stack.pop().unwrap()) |
100 | } else { | 100 | } else { |
101 | Err(CalcError::Parser( | 101 | Err(CalcError::Parser( |
102 | "Too many operators, Too little operands".to_string(), | 102 | "Too many operators, too few operands".to_string(), |
103 | )) | 103 | )) |
104 | } | 104 | } |
105 | } | 105 | } |