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

Modify ReentrancyGuard.sol to reduce the contract size by 0.028 KB per call #3514

Closed
abhi3700 opened this issue Jun 29, 2022 · 1 comment
Closed

Comments

@abhi3700
Copy link
Contributor

abhi3700 commented Jun 29, 2022

🧐 Motivation
In my codebase, I was trying to reduce the contract size.

📝 Details
The inheritance of ReentrancyGuard.sol inside a contract is leading to reduction in contract size of 0.028 KB per call of nonReentrant modifier.

Total no. of time nonReentrant called: 11

So, size per call = 0.308/11 = 0.028 KB

The verification is shown in the image below:
image

@abhi3700
Copy link
Contributor Author

It's merged.

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

No branches or pull requests

1 participant