Skip to content

Commit

Permalink
Merge branch 'main' into main
Browse files Browse the repository at this point in the history
  • Loading branch information
hensha256 authored Nov 6, 2024
2 parents 5104876 + 362c9ca commit a7aa748
Show file tree
Hide file tree
Showing 161 changed files with 560 additions and 462 deletions.
1 change: 0 additions & 1 deletion .forge-snapshots/BitMathLeastSignificantBitMaxUint128.snap

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/BitMathLeastSignificantBitMaxUint256.snap

This file was deleted.

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/BitMathMostSignificantBitMaxUint128.snap

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/BitMathMostSignificantBitMaxUint256.snap

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/BitMathMostSignificantBitSmallNumber.snap

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/ERC6909Claims approve.snap

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/ERC6909Claims burn.snap

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/ERC6909Claims mint.snap

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/ERC6909Claims transfer.snap

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/NoDelegateCall.snap

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/SwapMath_oneForZero_exactInCapped.snap

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/SwapMath_oneForZero_exactInPartial.snap

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/SwapMath_oneForZero_exactOutCapped.snap

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/SwapMath_oneForZero_exactOutPartial.snap

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/SwapMath_zeroForOne_exactInCapped.snap

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/SwapMath_zeroForOne_exactInPartial.snap

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/SwapMath_zeroForOne_exactOutCapped.snap

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/SwapMath_zeroForOne_exactOutPartial.snap

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/TickMathGetSqrtPriceAtTick.snap

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/TickMathGetTickAtSqrtPrice.snap

This file was deleted.

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/addLiquidity CA fee.snap

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/addLiquidity with empty hook.snap

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/addLiquidity with native token.snap

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/clear.snap

This file was deleted.

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/donate gas with 1 token.snap

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/donate gas with 2 tokens.snap

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/erc20 collect protocol fees.snap

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/extsload getFeeGrowthGlobals.snap

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/extsload getFeeGrowthInside.snap

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/extsload getLiquidity.snap

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/extsload getPositionInfo.snap

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/extsload getPositionLiquidity.snap

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/extsload getSlot0.snap

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/extsload getTickBitmap.snap

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/extsload getTickFeeGrowthOutside.snap

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/extsload getTickInfo.snap

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/extsload getTickLiquidity.snap

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/getReserves.snap

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/initialize.snap

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/native collect protocol fees.snap

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/poolManager bytecode size.snap

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/removeLiquidity CA fee.snap

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/removeLiquidity with empty hook.snap

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/removeLiquidity with native token.snap

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/set protocol fee.snap

This file was deleted.

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/simple addLiquidity.snap

This file was deleted.

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/simple removeLiquidity.snap

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/simple swap with native.snap

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/simple swap.snap

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/sparse external sload.snap

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/swap CA custom curve + swap noop.snap

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/swap CA fee on unspecified.snap

This file was deleted.

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/swap against liquidity.snap

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/swap burn 6909 for input.snap

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/swap burn native 6909 for input.snap

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/swap mint native output as 6909.snap

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/swap mint output as 6909.snap

This file was deleted.

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/swap with dynamic fee.snap

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/swap with hooks.snap

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/swap with lp fee and protocol fee.snap

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/swap with return dynamic fee.snap

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

1 change: 0 additions & 1 deletion .forge-snapshots/update dynamic fee in before swap.snap

This file was deleted.

3 changes: 0 additions & 3 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -1,9 +1,6 @@
[submodule "lib/forge-std"]
path = lib/forge-std
url = https://github.com/foundry-rs/forge-std
[submodule "lib/forge-gas-snapshot"]
path = lib/forge-gas-snapshot
url = https://github.com/marktoda/forge-gas-snapshot
[submodule "lib/solmate"]
path = lib/solmate
url = https://github.com/transmissions11/solmate
Expand Down
3 changes: 2 additions & 1 deletion .prettierignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,5 @@ out
lib/
cache/
*.sol
dist/
dist/
snapshots/
1 change: 0 additions & 1 deletion lib/forge-gas-snapshot
Submodule forge-gas-snapshot deleted from 9161f7
1 change: 0 additions & 1 deletion remappings.txt
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
@ensdomains/=node_modules/@ensdomains/
@openzeppelin/=lib/openzeppelin-contracts/
ds-test/=lib/forge-std/lib/ds-test/src/
forge-gas-snapshot/=lib/forge-gas-snapshot/src/
forge-std/=lib/forge-std/src/
hardhat/=node_modules/hardhat/
solmate/=lib/solmate/
3 changes: 3 additions & 0 deletions snapshots/ClearTest.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"clear": "1717"
}
6 changes: 6 additions & 0 deletions snapshots/CustomAccountingTest.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"addLiquidity CA fee": "170695",
"removeLiquidity CA fee": "141199",
"swap CA custom curve + swap noop": "124402",
"swap CA fee on unspecified": "154572"
}
9 changes: 9 additions & 0 deletions snapshots/ERC6909ClaimsTest.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
{
"ERC6909Claims approve": "46323",
"ERC6909Claims burn": "29389",
"ERC6909Claims mint": "46603",
"ERC6909Claims transfer": "51756",
"ERC6909Claims transferFrom as operator": "54437",
"ERC6909Claims transferFrom with approval": "59939",
"ERC6909Claims transferFrom with infinite approval": "56770"
}
3 changes: 3 additions & 0 deletions snapshots/ExtsloadTest.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"sparse external sload": "2164"
}
4 changes: 4 additions & 0 deletions snapshots/ModifyLiquidityTest.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"add liquidity to already existing position with salt": "144401",
"create new liquidity to a position with salt": "292593"
}
3 changes: 3 additions & 0 deletions snapshots/PoolManagerInitializeTest.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"initialize": "51532"
}
24 changes: 24 additions & 0 deletions snapshots/PoolManagerTest.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
{
"addLiquidity with empty hook": "274012",
"addLiquidity with native token": "135001",
"donate gas with 1 token": "106214",
"donate gas with 2 tokens": "145510",
"erc20 collect protocol fees": "57500",
"native collect protocol fees": "59643",
"poolManager bytecode size": "24050",
"removeLiquidity with empty hook": "130613",
"removeLiquidity with native token": "112523",
"simple addLiquidity": "161276",
"simple addLiquidity second addition same range": "98731",
"simple removeLiquidity": "85099",
"simple removeLiquidity some liquidity remains": "92986",
"simple swap": "123144",
"simple swap with native": "108434",
"swap against liquidity": "116527",
"swap against liquidity with native token": "105569",
"swap burn 6909 for input": "129285",
"swap burn native 6909 for input": "118672",
"swap mint native output as 6909": "139620",
"swap mint output as 6909": "154985",
"swap with hooks": "132165"
}
3 changes: 3 additions & 0 deletions snapshots/ProtocolFeesTest.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"set protocol fee": "31730"
}
3 changes: 3 additions & 0 deletions snapshots/SkipCallsTest.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"swap skips hook call if hook is caller": "206030"
}
10 changes: 10 additions & 0 deletions snapshots/SqrtPriceMathTest.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
{
"getAmount0Delta_gasCostForAmount0WhereRoundUpIsFalse": "243",
"getAmount0Delta_gasCostForAmount0WhereRoundUpIsTrue": "360",
"getAmount1Delta_gasCostForAmount1WhereRoundUpIsFalse": "229",
"getAmount1Delta_gasCostForAmount1WhereRoundUpIsTrue": "264",
"getNextSqrtPriceFromInput_zeroForOneEqualsFalseGas": "316",
"getNextSqrtPriceFromInput_zeroForOneEqualsTrueGas": "539",
"getNextSqrtPriceFromOutput_zeroForOneEqualsFalseGas": "544",
"getNextSqrtPriceFromOutput_zeroForOneEqualsTrueGas": "214"
}
Loading

0 comments on commit a7aa748

Please sign in to comment.