Skip to content

Commit

Permalink
fix: incorrect handling of hints in r1cs solver
Browse files Browse the repository at this point in the history
  • Loading branch information
gbotrel committed Nov 13, 2021
1 parent 1387c60 commit e116a82
Show file tree
Hide file tree
Showing 6 changed files with 36 additions and 6 deletions.
7 changes: 6 additions & 1 deletion internal/backend/bls12-377/cs/r1cs.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 6 additions & 1 deletion internal/backend/bls12-381/cs/r1cs.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 6 additions & 1 deletion internal/backend/bls24-315/cs/r1cs.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 6 additions & 1 deletion internal/backend/bn254/cs/r1cs.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 6 additions & 1 deletion internal/backend/bw6-761/cs/r1cs.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -202,7 +202,12 @@ func (cs *R1CS) solveConstraint(r compiled.R1C, solution *solution) error {

// first we check if this is a hint wire
if hint, ok := cs.MHints[vID]; ok {
return solution.solveWithHint(vID, hint)
if err := solution.solveWithHint(vID, hint); err != nil {
return err
}
v := solution.computeTerm(t)
val.Add(val, &v)
return nil
}

if loc != 0 {
Expand Down

0 comments on commit e116a82

Please sign in to comment.