forked from privacy-scaling-explorations/zkevm-circuits
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Change ExecError related functions to be associated-fns (privacy-scal…
…ing-explorations#1450) ### Description This PR attempts to associate the function `get_step_reported_error` to `ExecError`. ### Issue Link Resolves privacy-scaling-explorations#1181 ### Type of change - [x ] Bug fix (non-breaking change which fixes an issue) - [ ] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [ ] This change requires a documentation update ### Contents ### Rationale We wanted to move the function `get_step_reported_error` to an `imp ExecError`, I also moved the part related to `OogError` to its own associated function `From<OpCodeId> for OogError`. I changed an if/else block into a match expecting to handle more errors for CREATE/2. Personally I would update the function `get_step_reported_error` to take as input an `GethExecStep` and in that case directly implement it as a `From<GethExecStep> for ExecError` but the return type should be changed to `Option<ExecError>` since the step may not have an error (step.error is optional). ### How Has This Been Tested? No tests were added as no new functionalities were added.
- Loading branch information
Raphael
authored
Jun 8, 2023
1 parent
06cce9f
commit 9620822
Showing
2 changed files
with
55 additions
and
42 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