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

Remove the storage associated with decimals #2502

Merged
merged 7 commits into from Feb 4, 2021

Conversation

Amxx
Copy link
Collaborator

@Amxx Amxx commented Feb 2, 2021

Reduces the gas cost of deploying an ERC20 (avoid an sstore), and the gas cost of reading decimal count (avoid an ssload).
Changing decimals should be done by overriding the decimal function, as shown in the mocks.

PR Checklist

  • Tests
  • Documentation
  • Changelog entry

contracts/token/ERC20/ERC20.sol Outdated Show resolved Hide resolved
contracts/token/ERC20/ERC20.sol Outdated Show resolved Hide resolved
CHANGELOG.md Outdated Show resolved Hide resolved
Amxx and others added 4 commits February 4, 2021 19:33
Co-authored-by: Francisco Giordano <frangio.1@gmail.com>
Co-authored-by: Francisco Giordano <frangio.1@gmail.com>
Co-authored-by: Francisco Giordano <frangio.1@gmail.com>
Copy link
Contributor

@frangio frangio left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants