issue 580: generate a witess if needed during division
@@ -946,7 +946,7 @@ pub fn evaluate_udiv(
//range check q<=a
try_range_constraint(q_witness, bit_size, evaluator);
// a-b*q-r = 0
- let mut d = mul(&rhs.expression, &Expression::from(&q_witness));
+ let mut d = mul_with_witness(evaluator, &rhs.expression, &Expression::from(&q_witness));
d = add(&d, FieldElement::one(), &Expression::from(&r_witness));
d = mul_with_witness(evaluator, &d, &predicate.expression);
let div_eucl = subtract(&pa, FieldElement::one(), &d);
