@@ -228,7 +228,7 @@ where
228228}
229229
230230fn print_constraints_name_on_error_index < G1 , G2 , C1 , C2 > (
231- err : SuperNovaError ,
231+ err : & SuperNovaError ,
232232 running_claim : & RunningClaim < G1 , G2 , C1 , C2 > ,
233233 num_augmented_circuits : usize ,
234234) where
@@ -238,7 +238,7 @@ fn print_constraints_name_on_error_index<G1, G2, C1, C2>(
238238 C2 : StepCircuit < G2 :: Scalar > ,
239239{
240240 match err {
241- SuperNovaError :: UnSatIndex ( msg, index) if msg == "r_primary" => {
241+ SuperNovaError :: UnSatIndex ( msg, index) if * msg == "r_primary" => {
242242 let circuit_primary: SuperNovaAugmentedCircuit < ' _ , G2 , C1 > = SuperNovaAugmentedCircuit :: new (
243243 & running_claim. params . augmented_circuit_params_primary ,
244244 None ,
@@ -249,10 +249,10 @@ fn print_constraints_name_on_error_index<G1, G2, C1, C2>(
249249 let mut cs: TestShapeCS < G1 > = TestShapeCS :: new ( ) ;
250250 let _ = circuit_primary. synthesize ( & mut cs) ;
251251 cs. constraints
252- . get ( index)
252+ . get ( * index)
253253 . tap_some ( |constraint| debug ! ( "{msg} failed at constraint {}" , constraint. 3 ) ) ;
254254 }
255- SuperNovaError :: UnSatIndex ( msg, index) if msg == "r_secondary" || msg == "l_secondary" => {
255+ SuperNovaError :: UnSatIndex ( msg, index) if * msg == "r_secondary" || * msg == "l_secondary" => {
256256 let circuit_secondary: SuperNovaAugmentedCircuit < ' _ , G1 , C2 > = SuperNovaAugmentedCircuit :: new (
257257 & running_claim. params . augmented_circuit_params_secondary ,
258258 None ,
@@ -263,7 +263,7 @@ fn print_constraints_name_on_error_index<G1, G2, C1, C2>(
263263 let mut cs: TestShapeCS < G2 > = TestShapeCS :: new ( ) ;
264264 let _ = circuit_secondary. synthesize ( & mut cs) ;
265265 cs. constraints
266- . get ( index)
266+ . get ( * index)
267267 . tap_some ( |constraint| debug ! ( "{msg} failed at constraint {}" , constraint. 3 ) ) ;
268268 }
269269 _ => ( ) ,
@@ -440,7 +440,7 @@ where
440440 )
441441 . map_err ( |err| {
442442 print_constraints_name_on_error_index (
443- err,
443+ & err,
444444 & running_claims[ augmented_circuit_index] ,
445445 test_rom. num_circuits ( ) ,
446446 )
@@ -478,8 +478,8 @@ fn test_trivial_nivc() {
478478
479479// In the following we use 1 to refer to the primary, and 2 to refer to the secondary circuit
480480fn test_recursive_circuit_with < G1 , G2 > (
481- primary_params : SuperNovaAugmentedCircuitParams ,
482- secondary_params : SuperNovaAugmentedCircuitParams ,
481+ primary_params : & SuperNovaAugmentedCircuitParams ,
482+ secondary_params : & SuperNovaAugmentedCircuitParams ,
483483 ro_consts1 : ROConstantsCircuit < G2 > ,
484484 ro_consts2 : ROConstantsCircuit < G1 > ,
485485 num_constraints_primary : usize ,
@@ -492,7 +492,7 @@ fn test_recursive_circuit_with<G1, G2>(
492492 let step_circuit1 = TrivialTestCircuit :: default ( ) ;
493493 let arity1 = step_circuit1. arity ( ) ;
494494 let circuit1: SuperNovaAugmentedCircuit < ' _ , G2 , TrivialTestCircuit < <G2 as Group >:: Base > > =
495- SuperNovaAugmentedCircuit :: new ( & primary_params, None , & step_circuit1, ro_consts1. clone ( ) , 2 ) ;
495+ SuperNovaAugmentedCircuit :: new ( primary_params, None , & step_circuit1, ro_consts1. clone ( ) , 2 ) ;
496496 let mut cs: ShapeCS < G1 > = ShapeCS :: new ( ) ;
497497 if let Err ( e) = circuit1. synthesize ( & mut cs) {
498498 panic ! ( "{}" , e)
@@ -505,7 +505,7 @@ fn test_recursive_circuit_with<G1, G2>(
505505 let arity2 = step_circuit2. arity ( ) ;
506506 let circuit2: SuperNovaAugmentedCircuit < ' _ , G1 , TrivialSecondaryCircuit < <G1 as Group >:: Base > > =
507507 SuperNovaAugmentedCircuit :: new (
508- & secondary_params,
508+ secondary_params,
509509 None ,
510510 & step_circuit2,
511511 ro_consts2. clone ( ) ,
@@ -535,7 +535,7 @@ fn test_recursive_circuit_with<G1, G2>(
535535 ) ;
536536 let step_circuit = TrivialTestCircuit :: default ( ) ;
537537 let circuit1: SuperNovaAugmentedCircuit < ' _ , G2 , TrivialTestCircuit < <G2 as Group >:: Base > > =
538- SuperNovaAugmentedCircuit :: new ( & primary_params, Some ( inputs1) , & step_circuit, ro_consts1, 2 ) ;
538+ SuperNovaAugmentedCircuit :: new ( primary_params, Some ( inputs1) , & step_circuit, ro_consts1, 2 ) ;
539539 if let Err ( e) = circuit1. synthesize ( & mut cs1) {
540540 panic ! ( "{}" , e)
541541 }
@@ -561,7 +561,7 @@ fn test_recursive_circuit_with<G1, G2>(
561561 let step_circuit = TrivialSecondaryCircuit :: default ( ) ;
562562 let circuit2: SuperNovaAugmentedCircuit < ' _ , G1 , TrivialSecondaryCircuit < <G1 as Group >:: Base > > =
563563 SuperNovaAugmentedCircuit :: new (
564- & secondary_params,
564+ secondary_params,
565565 Some ( inputs2) ,
566566 & step_circuit,
567567 ro_consts2,
@@ -584,5 +584,5 @@ fn test_recursive_circuit() {
584584 let ro_consts1: ROConstantsCircuit < G2 > = PoseidonConstantsCircuit :: default ( ) ;
585585 let ro_consts2: ROConstantsCircuit < G1 > = PoseidonConstantsCircuit :: default ( ) ;
586586
587- test_recursive_circuit_with :: < G1 , G2 > ( params1, params2, ro_consts1, ro_consts2, 9835 , 12035 ) ;
587+ test_recursive_circuit_with :: < G1 , G2 > ( & params1, & params2, ro_consts1, ro_consts2, 9835 , 12035 ) ;
588588}
0 commit comments