Open code423n4 opened 2 years ago
Line 50: current++;
https://github.com/Swivel-Finance/swivel/blob/2471ea5cda53568df5e5515153c6962f151bf358/contracts/v2/destributor/Destributor.sol#L50
Line 46: bytes32 hashStruct = Hash.permit(o, spender, a, nonces[o]++, d);
https://github.com/Swivel-Finance/swivel/blob/2471ea5cda53568df5e5515153c6962f151bf358/contracts/v2/marketplace/Erc2612.sol#L46
Line 19: for (uint256 i = 0; i < len; i++) {
https://github.com/Swivel-Finance/swivel/blob/2471ea5cda53568df5e5515153c6962f151bf358/contracts/v2/destributor/MerkleProof.sol#L19
++i costs less gas than i++, especially when it's used in for-loops (--i/i-- too)
https://github.com/Swivel-Finance/swivel/blob/2471ea5cda53568df5e5515153c6962f151bf358/contracts/v2/destributor/Destributor.sol#L50
https://github.com/Swivel-Finance/swivel/blob/2471ea5cda53568df5e5515153c6962f151bf358/contracts/v2/marketplace/Erc2612.sol#L46
https://github.com/Swivel-Finance/swivel/blob/2471ea5cda53568df5e5515153c6962f151bf358/contracts/v2/destributor/MerkleProof.sol#L19