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

Unlocked Compiler Versions - Floating pragmas #9

Open
2 tasks
sangier opened this issue Jul 31, 2024 · 1 comment
Open
2 tasks

Unlocked Compiler Versions - Floating pragmas #9

sangier opened this issue Jul 31, 2024 · 1 comment
Labels
good practices Good code practices

Comments

@sangier
Copy link
Contributor

sangier commented Jul 31, 2024

The contracts have unlocked compiler versions.

An unlocked compiler version allows the user to compile it at or above a particular version. This can lead to differences in the generated bytecodes between the compilations that can be different to what was originally tested. Additionally it can led to ambiguity when debugging specific compilers related bug that may occur.
[Extra Ref]: (https://consensys.github.io/smart-contract-best-practices/development-recommendations/solidity-specific/locking-pragmas/)

  • Decide which solidity version we wanna use.
  • Lock the compiler version e.g. pragma solidity 0.8.25;
@sangier sangier added the good practices Good code practices label Jul 31, 2024
@sangier
Copy link
Contributor Author

sangier commented Jul 31, 2024

Just noted that the new solidity version 0.8.26 allows custom error support inside require statement. IMO we should use this type of error management instead of revert

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

No branches or pull requests

1 participant