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

Declare variables immutable when possible #26

Open
kitty-the-kat opened this issue Jan 11, 2023 · 1 comment
Open

Declare variables immutable when possible #26

kitty-the-kat opened this issue Jan 11, 2023 · 1 comment

Comments

@kitty-the-kat
Copy link
Contributor

An immutable variable can provide gas saving compared to a non-immutable variable.

Technical Details

The IsGTrancheSet boolean is set only once in GMigration.sol and can be immutable.

Impact

Gas savings.

Recommendation

Make IsGTrancheSet immutable for gas savings.

@kitty-the-kat
Copy link
Contributor Author

acknowledged: Won't fix
reasoning: migration contracts is intended to run once, and the gas saving is minimal.

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

When branches are created from issues, their pull requests are automatically linked.

1 participant