Tenderize / tender-core

Smart contracts for the core Tenderize protocol
MIT License
6 stars 3 forks source link

Use external instead of public modifier #237

Closed kyriediculous closed 2 years ago

kyriediculous commented 2 years ago

Functions can be declared as external instead of public if they are never called from within the contract itself to save gas.

Correct. This is because external functions read from calldata while public functions copy the arguments to memory. Calldata is cheaper to operate on.

reubenr0d commented 2 years ago

Closed with https://github.com/Tenderize/tender-core/commit/2376391776e34989c46bd261734af503ec457c1b