Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix formatting #22

Merged
merged 1 commit into from
Sep 15, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 1 addition & 3 deletions ethereum/contracts/zksync/Verifier.sol
Original file line number Diff line number Diff line change
Expand Up @@ -233,7 +233,7 @@ contract Verifier is IVerifier {

/// @dev flip of 0xe000000000000000000000000000000000000000000000000000000000000000;
uint256 internal constant FR_MASK = 0x1fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff;

// non residues
uint256 internal constant NON_RESIDUES_0 = 0x5;
uint256 internal constant NON_RESIDUES_1 = 0x7;
Expand Down Expand Up @@ -276,7 +276,6 @@ contract Verifier is IVerifier {
/// [table_type] - lookup table type commitment
function _loadVerificationKey() internal pure virtual {
assembly {

// gate setup commitments
mstore(VK_GATE_SETUP_0_X_SLOT, 0x14c289d746e37aa82ec428491881c4732766492a8bc2e8e3cca2000a40c0ea27)
mstore(VK_GATE_SETUP_0_Y_SLOT, 0x2f617a7eb9808ad9843d1e080b7cfbf99d61bb1b02076c905f31adb12731bc41)
Expand Down Expand Up @@ -328,7 +327,6 @@ contract Verifier is IVerifier {
// table type commitment
mstore(VK_LOOKUP_TABLE_TYPE_X_SLOT, 0x2f85df2d6249ccbcc11b91727333cc800459de6ee274f29c657c8d56f6f01563)
mstore(VK_LOOKUP_TABLE_TYPE_Y_SLOT, 0x088e1df178c47116a69c3c8f6d0c5feb530e2a72493694a623b1cceb7d44a76c)

}
}

Expand Down
12 changes: 10 additions & 2 deletions ethereum/contracts/zksync/facets/Executor.sol
Original file line number Diff line number Diff line change
Expand Up @@ -352,11 +352,19 @@ contract ExecutorFacet is Base, IExecutor {
// We allow skipping the zkp verification for the test(net) environment
// If the proof is not empty, verify it, otherwise, skip the verification
if (_proof.serializedProof.length > 0) {
bool successVerifyProof = s.verifier.verify(proofPublicInput, _proof.serializedProof, _proof.recursiveAggregationInput);
bool successVerifyProof = s.verifier.verify(
proofPublicInput,
_proof.serializedProof,
_proof.recursiveAggregationInput
);
require(successVerifyProof, "p"); // Proof verification fail
}
// #else
bool successVerifyProof = s.verifier.verify(proofPublicInput, _proof.serializedProof, _proof.recursiveAggregationInput);
bool successVerifyProof = s.verifier.verify(
proofPublicInput,
_proof.serializedProof,
_proof.recursiveAggregationInput
);
require(successVerifyProof, "p"); // Proof verification fail
// #endif

Expand Down