-
Notifications
You must be signed in to change notification settings - Fork 57
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #225 from bufferhe4d/plusequal
Add += functionality
- Loading branch information
Showing
8 changed files
with
157 additions
and
20 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
fn main(pub xx: Field, yy: Field) -> Field { | ||
let mut zz = xx + yy; | ||
let mut zz2 = xx + yy; | ||
|
||
zz += 1; | ||
zz2 = zz2 + 1; | ||
|
||
zz *= zz; | ||
zz2 = zz2 * zz2; | ||
|
||
zz -= yy; | ||
zz2 = zz2 - yy; | ||
assert_eq(zz, zz2); | ||
|
||
return zz; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
@ noname.0.7.0 | ||
@ public inputs: 2 | ||
|
||
DoubleGeneric<1> | ||
DoubleGeneric<1> | ||
DoubleGeneric<1,1,-1> | ||
DoubleGeneric<1,1,-1> | ||
DoubleGeneric<1,0,-1,0,1> | ||
DoubleGeneric<1,0,-1,0,1> | ||
DoubleGeneric<0,0,-1,1> | ||
DoubleGeneric<0,0,-1,1> | ||
DoubleGeneric<1,1> | ||
DoubleGeneric<1,1,-1> | ||
DoubleGeneric<1,1> | ||
DoubleGeneric<1,1,-1> | ||
DoubleGeneric<1,-1> | ||
DoubleGeneric<1,-1> | ||
(0,0) -> (13,0) | ||
(1,0) -> (2,0) -> (3,0) | ||
(2,1) -> (3,1) -> (8,0) -> (10,0) | ||
(2,2) -> (4,0) | ||
(3,2) -> (5,0) | ||
(4,2) -> (6,0) -> (6,1) | ||
(5,2) -> (7,0) -> (7,1) | ||
(6,2) -> (9,0) | ||
(7,2) -> (11,0) | ||
(8,1) -> (9,1) | ||
(9,2) -> (12,0) -> (13,1) | ||
(10,1) -> (11,1) | ||
(11,2) -> (12,1) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
@ noname.0.7.0 | ||
@ public inputs: 2 | ||
|
||
v_4 == (v_2 + v_3 + 1) * (v_2 + v_3 + 1) | ||
v_5 == (v_2 + v_3 + 1) * (v_2 + v_3 + 1) | ||
-1 * v_3 + v_5 == (-1 * v_3 + v_4) * (1) | ||
-1 * v_3 + v_4 == (v_1) * (1) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters