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

♻️ Very safe transfer #1128

Merged
merged 4 commits into from
Oct 17, 2024
Merged

♻️ Very safe transfer #1128

merged 4 commits into from
Oct 17, 2024

Conversation

Vectorized
Copy link
Owner

Description

♻️

Checklist

Ensure you completed all of the steps below before submitting your pull request:

  • Ran forge fmt?
  • Ran forge test?

Pull requests with an incomplete checklist will be thrown out.

Copy link

github-actions bot commented Oct 17, 2024

Gas Snapshot Comparison Report

Generated at commit : f53292d, Compared to commit : 7f72ce1

Contract Name Test Name Main Gas PR Gas Diff
ERC4626Test testDepositWithNoApprovalReverts() 16951 17076 125
testDepositWithNotEnoughApprovalReverts() 90749 90874 125
testMintWithNoApprovalReverts() 16925 17050 125
testMintZero() 53927 53924 -3
testMultipleMintDepositRedeemWithdraw() 412861 412842 -19
testRedeemWithNotEnoughShareAmountReverts() 143774 143771 -3
testTryGetAssetDecimals() 30687274 30755448 68174
testUseVirtualShares() 2427648 2435672 8024
testVaultInteractionsForSomeoneElse() 297831 297821 -10
testVirtualSharesMultipleMintDepositRedeemWithdraw() 1614679 1618669 3990
testWithdrawWithNotEnoughUnderlyingAmountReverts() 144907 144904 -3
testWithdrawZero() 52056 52053 -3
test__codesize() 36903 36923 20
SafeTransferLibTest testApproveWithMissingReturn() 32462 32633 171
testApproveWithNonContract() 2967 - -
testApproveWithRetry() 789740 789930 190
testApproveWithRetryWithNonContract() 2990 - -
testApproveWithReturnsFalseReverts() 10122 10253 131
testApproveWithReturnsTooLittleReverts() 10026 10157 131
testApproveWithReturnsTooMuch() 32913 32932 19
testApproveWithRevertingReverts() 9983 10114 131
testApproveWithStandardERC20() 32348 32367 19
testBalanceOfStandardERC20() 7852 7808 -44
testForceTransferETHToGriever() 1511587 1511700 113
testPermit2OnDAI() 90296 90273 -23
testSimplePermit2AndPermit2TransferFrom() 1136300 1137384 1084
testSimplePermit2AndPermit2TransferFromGas() 141119 141199 80
testTransferAllETHToContractWithoutFallbackReverts() 10782 10793 11
testTransferAllFromWithStandardERC20() 33699 33696 -3
testTransferAllWithStandardERC20() 31014 31011 -3
testTransferETH() 34622 34600 -22
testTransferETHToContractWithoutFallbackReverts() 10851 10873 22
testTransferFromWithMissingReturn() 542551 562108 19557
testTransferFromWithNonContract() 3066 - -
testTransferFromWithReturnsFalseReverts() 508931 528170 19239
testTransferFromWithReturnsTooLittleReverts() 508642 528103 19461
testTransferFromWithReturnsTooMuch() 543464 562742 19278
testTransferFromWithRevertingReverts() 501397 520689 19292
testTransferFromWithStandardERC20() 541672 560961 19289
testTransferWithMissingReturn() 529179 548553 19374
testTransferWithNonContract() 3010 - -
testTransferWithReturnsFalseReverts() 506018 525381 19363
testTransferWithReturnsTooLittleReverts() 505585 525265 19680
testTransferWithReturnsTooMuch() 529956 549119 19163
testTransferWithRevertingReverts() 776822 525153 -251669
testTransferWithStandardERC20() 530079 549269 19190
testTryTransferETH() 148701 148767 66
test__codesize() 65981 67384 1403
testApproveWithNonContractReverts() - 6901 -
testApproveWithRetryWithNonContractReverts() - 7290 -
testTransferFromWithNonContractReverts() - 8184 -
testTransferWithNonContractReverts() - 6908 -

@Vectorized
Copy link
Owner Author

@Philogy Help me double check this if you are free. My brain is only 10% now.

@Vectorized Vectorized merged commit e9c03bf into main Oct 17, 2024
11 checks passed
@Vectorized Vectorized deleted the very-safe-transfer branch October 17, 2024 09:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant