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(werc20): WERC20 refactors and handling of fallback and receive functions #2057
Conversation
Codecov Report
Additional details and impacted files@@ Coverage Diff @@
## main #2057 +/- ##
==========================================
- Coverage 70.16% 70.15% -0.01%
==========================================
Files 340 340
Lines 25448 25451 +3
==========================================
Hits 17856 17856
- Misses 6679 6682 +3
Partials 913 913
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
final comments
Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com>
Description
This PR refactors some functionality on the WERC20 precompile as discovered through integration tests. In particular:
deposit
function is payable and thus would trigger the minting/burning mechanism because it's a change of account balance. We manually override it by using the stateDB directlyreceive
andfallback
functions which will not have amethodID
, done in the common precompile setupCloses #XXX