Skip to content

Commit

Permalink
Using native elem type for unary operation.
Browse files Browse the repository at this point in the history
  • Loading branch information
lvella committed Oct 25, 2023
1 parent 75844d4 commit 8c86254
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions riscv_executor/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -672,8 +672,8 @@ impl<'a, 'b, F: FieldElement> Executor<'a, 'b, F> {
Expression::UnaryOperation(op, arg) => {
let arg = self.eval_expression(arg)[0];
let result = match op {
ast::parsed::UnaryOperator::Plus => arg.s(),
ast::parsed::UnaryOperator::Minus => -arg.s(),
ast::parsed::UnaryOperator::Plus => arg.0,
ast::parsed::UnaryOperator::Minus => -arg.0,
ast::parsed::UnaryOperator::LogicalNot => todo!(),
};

Expand Down

0 comments on commit 8c86254

Please sign in to comment.