golf-course
golf-course copied to clipboard
A list of common Solidity optimization tips and myths.
As you mentioned , in non-zero case , we should set it as nonZero != 0 in order to save 6 gas . But what if the nonZero goes negative...
This pr adds a few more tips to the `README.md` file. Some notes/thoughts: - I spent a lot of time thinking about the top level "title" of each tip. On...
Keeping track of miscellaneous optimizations. Some more useful than others: - [ ] function ordering #2 - [ ] `(a, b) = (b, a);` - [x] [`payable` functions 24 gas...
Gm, sers, I've added a tip about ordering functions by Method ID! If more contributions are welcome, I'll add new tips as I discover them. 🌸