code-423n4 / 2022-01-sherlock-findings

0 stars 0 forks source link

Inline one time use functions, #232

Closed code423n4 closed 2 years ago

code423n4 commented 2 years ago

Handle

robee

Vulnerability details

The following functions are used exactly once. Therefore you can inline them and save gas and improve code clearness.

    Manager.sol, _sweep
    Sherlock.sol, _beforeTokenTransfer
jack-the-pug commented 2 years ago

Solidity's complier adds a simple inliner to the low-level optimizer since 0.8.2.

See: https://blog.soliditylang.org/2021/03/02/saving-gas-with-simple-inliner/