@pendle/core-v2 0.11.8-testnet → 0.11.10-testnet
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/artifacts/contracts/SuperComposableYield/SCY-implementations/AaveV3/PendleAaveV3SCY.sol/PendleAaveV3SCY.dbg.json +1 -1
- package/build/artifacts/contracts/SuperComposableYield/SCY-implementations/AaveV3/WadRayMath.sol/WadRayMath.dbg.json +1 -1
- package/build/artifacts/contracts/SuperComposableYield/SCY-implementations/BenQi/PendleQiSAvaxSCY.sol/PendleQiSAvaxSCY.dbg.json +1 -1
- package/build/artifacts/contracts/SuperComposableYield/SCY-implementations/BenQi/PendleQiTokenSCY.sol/PendleQiTokenSCY.dbg.json +1 -1
- package/build/artifacts/contracts/SuperComposableYield/SCY-implementations/BenQi/PendleSAvaxSCY.sol/PendleSAvaxSCY.dbg.json +1 -1
- package/build/artifacts/contracts/SuperComposableYield/SCY-implementations/Euler/PendleEulerSCY.sol/PendleEulerSCY.dbg.json +1 -1
- package/build/artifacts/contracts/SuperComposableYield/SCY-implementations/PendleERC4626SCY.sol/PendleERC4626SCY.dbg.json +1 -1
- package/build/artifacts/contracts/SuperComposableYield/SCY-implementations/PendleStargateSCY.sol/PendleStargateSCY.dbg.json +1 -1
- package/build/artifacts/contracts/SuperComposableYield/SCY-implementations/PendleWstEthSCY.sol/PendleWstEthSCY.dbg.json +1 -1
- package/build/artifacts/contracts/SuperComposableYield/SCY-implementations/PendleYearnVaultSCY.sol/PendleYearnVaultSCY.dbg.json +1 -1
- package/build/artifacts/contracts/SuperComposableYield/SCY-implementations/TraderJoe/PendleSJoeSCY.sol/PendleSJoeSCY.dbg.json +1 -1
- package/build/artifacts/contracts/SuperComposableYield/base-implementations/SCYBase.sol/SCYBase.dbg.json +1 -1
- package/build/artifacts/contracts/SuperComposableYield/base-implementations/SCYBaseWithRewards.sol/SCYBaseWithRewards.dbg.json +1 -1
- package/build/artifacts/contracts/core/LiquidityMining/CelerAbstracts/CelerReceiverUpg.sol/CelerReceiverUpg.dbg.json +1 -1
- package/build/artifacts/contracts/core/LiquidityMining/CelerAbstracts/CelerSenderUpg.sol/CelerSenderUpg.dbg.json +1 -1
- package/build/artifacts/contracts/core/LiquidityMining/GaugeController/PendleGaugeControllerBaseUpg.sol/PendleGaugeControllerBaseUpg.dbg.json +1 -1
- package/build/artifacts/contracts/core/LiquidityMining/GaugeController/PendleGaugeControllerMainchainUpg.sol/PendleGaugeControllerMainchainUpg.dbg.json +1 -1
- package/build/artifacts/contracts/core/LiquidityMining/GaugeController/PendleGaugeControllerSidechainUpg.sol/PendleGaugeControllerSidechainUpg.dbg.json +1 -1
- package/build/artifacts/contracts/core/LiquidityMining/PendleGauge.sol/PendleGauge.dbg.json +1 -1
- package/build/artifacts/contracts/core/LiquidityMining/VotingController/PendleVotingControllerUpg.sol/PendleVotingControllerUpg.dbg.json +1 -1
- package/build/artifacts/contracts/core/LiquidityMining/VotingController/VotingControllerStorageUpg.sol/VotingControllerStorageUpg.dbg.json +1 -1
- package/build/artifacts/contracts/core/LiquidityMining/VotingEscrow/VotingEscrowPendleMainchain.sol/VotingEscrowPendleMainchain.dbg.json +1 -1
- package/build/artifacts/contracts/core/LiquidityMining/VotingEscrow/VotingEscrowPendleMainchain.sol/VotingEscrowPendleMainchain.json +2 -2
- package/build/artifacts/contracts/core/LiquidityMining/VotingEscrow/VotingEscrowPendleSidechain.sol/VotingEscrowPendleSidechain.dbg.json +1 -1
- package/build/artifacts/contracts/core/LiquidityMining/VotingEscrow/VotingEscrowTokenBase.sol/VotingEscrowTokenBase.dbg.json +1 -1
- package/build/artifacts/contracts/core/Market/PendleMarket.sol/PendleMarket.dbg.json +1 -1
- package/build/artifacts/contracts/core/Market/PendleMarketFactory.sol/PendleMarketFactory.dbg.json +1 -1
- package/build/artifacts/contracts/core/PendleRouter.sol/PendleRouter.dbg.json +1 -1
- package/build/artifacts/contracts/core/PendleRouter.sol/PendleRouter.json +20 -2
- package/build/artifacts/contracts/core/YieldContracts/InterestManagerYT.sol/InterestManagerYT.dbg.json +1 -1
- package/build/artifacts/contracts/core/YieldContracts/PendlePrincipalToken.sol/PendlePrincipalToken.dbg.json +1 -1
- package/build/artifacts/contracts/core/YieldContracts/PendleYieldContractFactory.sol/PendleYieldContractFactory.dbg.json +1 -1
- package/build/artifacts/contracts/core/YieldContracts/PendleYieldToken.sol/PendleYieldToken.dbg.json +1 -1
- package/build/artifacts/contracts/core/actions/ActionAddRemoveLiq.sol/ActionAddRemoveLiq.dbg.json +1 -1
- package/build/artifacts/contracts/core/actions/ActionAddRemoveLiq.sol/ActionAddRemoveLiq.json +4 -4
- package/build/artifacts/contracts/core/actions/ActionCallback.sol/ActionCallback.dbg.json +1 -1
- package/build/artifacts/contracts/core/actions/ActionCallback.sol/ActionCallback.json +2 -2
- package/build/artifacts/contracts/core/actions/ActionMintRedeem.sol/ActionMintRedeem.dbg.json +1 -1
- package/build/artifacts/contracts/core/actions/ActionMintRedeem.sol/ActionMintRedeem.json +2 -2
- package/build/artifacts/contracts/core/actions/ActionMisc.sol/ActionMisc.dbg.json +1 -1
- package/build/artifacts/contracts/core/actions/ActionSwapPT.sol/ActionSwapPT.dbg.json +1 -1
- package/build/artifacts/contracts/core/actions/ActionSwapPT.sol/ActionSwapPT.json +2 -2
- package/build/artifacts/contracts/core/actions/ActionSwapPTYT.sol/ActionSwapPTYT.dbg.json +4 -0
- package/build/artifacts/contracts/core/actions/ActionSwapPTYT.sol/ActionSwapPTYT.json +185 -0
- package/build/artifacts/contracts/core/actions/ActionSwapYT.sol/ActionSwapYT.dbg.json +1 -1
- package/build/artifacts/contracts/core/actions/ActionSwapYT.sol/ActionSwapYT.json +2 -2
- package/build/artifacts/contracts/core/actions/base/ActionBaseMintRedeem.sol/ActionBaseMintRedeem.dbg.json +1 -1
- package/build/artifacts/contracts/core/actions/base/CallbackHelper.sol/CallbackHelper.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPActionAddRemoveLiq.sol/IPActionAddRemoveLiq.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPActionMintRedeem.sol/IPActionMintRedeem.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPActionSwapPT.sol/IPActionSwapPT.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPActionSwapPTYT.sol/IPActionSwapPTYT.dbg.json +4 -0
- package/build/artifacts/contracts/interfaces/IPActionSwapPTYT.sol/IPActionSwapPTYT.json +180 -0
- package/build/artifacts/contracts/interfaces/IPActionSwapYT.sol/IPActionSwapYT.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPAllAction.sol/IPAllAction.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPAllAction.sol/IPAllAction.json +169 -0
- package/build/artifacts/contracts/interfaces/IPMarket.sol/IPMarket.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPVotingController.sol/IPVotingController.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPVotingEscrow.sol/IPVotingEscrow.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPVotingEscrow.sol/IPVotingEscrow.json +93 -0
- package/build/artifacts/contracts/interfaces/ISuperComposableYield.sol/ISuperComposableYield.dbg.json +1 -1
- package/build/artifacts/contracts/libraries/RewardManager.sol/RewardManager.dbg.json +1 -1
- package/build/artifacts/contracts/libraries/RewardManagerAbstract.sol/RewardManagerAbstract.dbg.json +1 -1
- package/build/artifacts/contracts/libraries/VeBalanceLib.sol/VeBalanceLib.dbg.json +1 -1
- package/build/artifacts/contracts/libraries/VeHistoryLib.sol/Checkpoints.dbg.json +1 -1
- package/build/artifacts/contracts/libraries/helpers/PYIndex.sol/PYIndexLib.dbg.json +1 -1
- package/build/artifacts/contracts/libraries/helpers/SSTORE2Deployer.sol/SSTORE2Deployer.dbg.json +1 -1
- package/build/artifacts/contracts/libraries/kyberswap/AggregationRouterHelper.sol/AggregationRouterHelper.dbg.json +1 -1
- package/build/artifacts/contracts/libraries/kyberswap/KyberSwapHelper.sol/KyberSwapHelper.dbg.json +1 -1
- package/build/artifacts/contracts/libraries/math/MarketApproxLib.sol/MarketApproxPtInLib.dbg.json +1 -1
- package/build/artifacts/contracts/libraries/math/MarketApproxLib.sol/MarketApproxPtInLib.json +2 -2
- package/build/artifacts/contracts/libraries/math/MarketApproxLib.sol/MarketApproxPtOutLib.dbg.json +1 -1
- package/build/artifacts/contracts/libraries/math/MarketApproxLib.sol/MarketApproxPtOutLib.json +2 -2
- package/build/artifacts/contracts/libraries/math/MarketMathCore.sol/MarketMathCore.dbg.json +1 -1
- package/build/artifacts/contracts/libraries/math/Math.sol/Math.dbg.json +1 -1
- package/build/artifacts/contracts/libraries/math/WeekMath.sol/WeekMath.dbg.json +1 -1
- package/build/artifacts/contracts/libraries/solmate/SSTORE2.sol/SSTORE2.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/MarketMathStatic.sol/MarketMathStatic.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/MarketMathStatic.sol/MarketMathStatic.json +2 -2
- package/build/artifacts/contracts/offchain-helpers/RouterStatic.sol/RouterStatic.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/RouterStatic.sol/RouterStatic.json +210 -56
- package/build/artifacts/contracts/offchain-helpers/SSTORE2DeployerContract.sol/SSTORE2DeployerContract.dbg.json +1 -1
- package/contracts/core/LiquidityMining/VotingEscrow/VotingEscrowPendleMainchain.sol +6 -1
- package/contracts/core/PendleRouter.sol +10 -1
- package/contracts/core/actions/ActionAddRemoveLiq.sol +23 -2
- package/contracts/core/actions/ActionCallback.sol +39 -0
- package/contracts/core/actions/ActionSwapPTYT.sol +86 -0
- package/contracts/core/actions/base/CallbackHelper.sol +49 -1
- package/contracts/interfaces/IPActionSwapPTYT.sol +31 -0
- package/contracts/interfaces/IPAllAction.sol +2 -0
- package/contracts/interfaces/IPVotingEscrow.sol +1 -1
- package/contracts/libraries/math/MarketApproxLib.sol +117 -0
- package/contracts/offchain-helpers/MarketMathStatic.sol +69 -8
- package/contracts/offchain-helpers/RouterStatic.sol +76 -3
- package/deployments/43113-core.json +1 -1
- package/package.json +1 -3
- package/typechain-types/ActionSwapPTYT.ts +233 -0
- package/typechain-types/IPActionSwapPTYT.ts +233 -0
- package/typechain-types/IPAllAction.ts +138 -0
- package/typechain-types/IPVotingEscrow.ts +131 -0
- package/typechain-types/PendleFeeDistributorFactory.ts +97 -8
- package/typechain-types/PendleRouter.ts +19 -0
- package/typechain-types/RouterStatic.ts +174 -0
- package/typechain-types/factories/ActionAddRemoveLiq__factory.ts +1 -1
- package/typechain-types/factories/ActionCallback__factory.ts +1 -1
- package/typechain-types/factories/ActionMintRedeem__factory.ts +1 -1
- package/typechain-types/factories/ActionSwapPTYT__factory.ts +238 -0
- package/typechain-types/factories/ActionSwapPT__factory.ts +1 -1
- package/typechain-types/factories/ActionSwapYT__factory.ts +1 -1
- package/typechain-types/factories/IPActionSwapPTYT__factory.ts +195 -0
- package/typechain-types/factories/IPAllAction__factory.ts +169 -0
- package/typechain-types/factories/IPVotingEscrow__factory.ts +93 -0
- package/typechain-types/factories/MarketMathStatic__factory.ts +1 -1
- package/typechain-types/factories/PendleFeeDistributorFactory__factory.ts +81 -8
- package/typechain-types/factories/PendleFeeDistributor__factory.ts +1 -1
- package/typechain-types/factories/PendleMsgSendEndpointUpg__factory.ts +1 -1
- package/typechain-types/factories/PendleRouter__factory.ts +23 -1
- package/typechain-types/factories/RouterStatic__factory.ts +143 -1
- package/typechain-types/factories/VotingEscrowPendleMainchain__factory.ts +1 -1
- package/typechain-types/hardhat.d.ts +72 -117
- package/typechain-types/index.ts +16 -26
|
@@ -0,0 +1,180 @@
|
|
|
1
|
+
{
|
|
2
|
+
"_format": "hh-sol-artifact-1",
|
|
3
|
+
"contractName": "IPActionSwapPTYT",
|
|
4
|
+
"sourceName": "contracts/interfaces/IPActionSwapPTYT.sol",
|
|
5
|
+
"abi": [
|
|
6
|
+
{
|
|
7
|
+
"anonymous": false,
|
|
8
|
+
"inputs": [
|
|
9
|
+
{
|
|
10
|
+
"indexed": true,
|
|
11
|
+
"internalType": "address",
|
|
12
|
+
"name": "caller",
|
|
13
|
+
"type": "address"
|
|
14
|
+
},
|
|
15
|
+
{
|
|
16
|
+
"indexed": true,
|
|
17
|
+
"internalType": "address",
|
|
18
|
+
"name": "market",
|
|
19
|
+
"type": "address"
|
|
20
|
+
},
|
|
21
|
+
{
|
|
22
|
+
"indexed": true,
|
|
23
|
+
"internalType": "address",
|
|
24
|
+
"name": "receiver",
|
|
25
|
+
"type": "address"
|
|
26
|
+
},
|
|
27
|
+
{
|
|
28
|
+
"indexed": false,
|
|
29
|
+
"internalType": "int256",
|
|
30
|
+
"name": "netPtToAccount",
|
|
31
|
+
"type": "int256"
|
|
32
|
+
},
|
|
33
|
+
{
|
|
34
|
+
"indexed": false,
|
|
35
|
+
"internalType": "int256",
|
|
36
|
+
"name": "netYtToAccount",
|
|
37
|
+
"type": "int256"
|
|
38
|
+
}
|
|
39
|
+
],
|
|
40
|
+
"name": "SwapPtAndYt",
|
|
41
|
+
"type": "event"
|
|
42
|
+
},
|
|
43
|
+
{
|
|
44
|
+
"inputs": [
|
|
45
|
+
{
|
|
46
|
+
"internalType": "address",
|
|
47
|
+
"name": "receiver",
|
|
48
|
+
"type": "address"
|
|
49
|
+
},
|
|
50
|
+
{
|
|
51
|
+
"internalType": "address",
|
|
52
|
+
"name": "market",
|
|
53
|
+
"type": "address"
|
|
54
|
+
},
|
|
55
|
+
{
|
|
56
|
+
"internalType": "uint256",
|
|
57
|
+
"name": "exactPtIn",
|
|
58
|
+
"type": "uint256"
|
|
59
|
+
},
|
|
60
|
+
{
|
|
61
|
+
"internalType": "uint256",
|
|
62
|
+
"name": "minYtOut",
|
|
63
|
+
"type": "uint256"
|
|
64
|
+
},
|
|
65
|
+
{
|
|
66
|
+
"components": [
|
|
67
|
+
{
|
|
68
|
+
"internalType": "uint256",
|
|
69
|
+
"name": "guessMin",
|
|
70
|
+
"type": "uint256"
|
|
71
|
+
},
|
|
72
|
+
{
|
|
73
|
+
"internalType": "uint256",
|
|
74
|
+
"name": "guessMax",
|
|
75
|
+
"type": "uint256"
|
|
76
|
+
},
|
|
77
|
+
{
|
|
78
|
+
"internalType": "uint256",
|
|
79
|
+
"name": "guessOffchain",
|
|
80
|
+
"type": "uint256"
|
|
81
|
+
},
|
|
82
|
+
{
|
|
83
|
+
"internalType": "uint256",
|
|
84
|
+
"name": "maxIteration",
|
|
85
|
+
"type": "uint256"
|
|
86
|
+
},
|
|
87
|
+
{
|
|
88
|
+
"internalType": "uint256",
|
|
89
|
+
"name": "eps",
|
|
90
|
+
"type": "uint256"
|
|
91
|
+
}
|
|
92
|
+
],
|
|
93
|
+
"internalType": "struct ApproxParams",
|
|
94
|
+
"name": "guessTotalPtToSwap",
|
|
95
|
+
"type": "tuple"
|
|
96
|
+
}
|
|
97
|
+
],
|
|
98
|
+
"name": "swapExactPtForYt",
|
|
99
|
+
"outputs": [
|
|
100
|
+
{
|
|
101
|
+
"internalType": "uint256",
|
|
102
|
+
"name": "netYtOut",
|
|
103
|
+
"type": "uint256"
|
|
104
|
+
}
|
|
105
|
+
],
|
|
106
|
+
"stateMutability": "nonpayable",
|
|
107
|
+
"type": "function"
|
|
108
|
+
},
|
|
109
|
+
{
|
|
110
|
+
"inputs": [
|
|
111
|
+
{
|
|
112
|
+
"internalType": "address",
|
|
113
|
+
"name": "receiver",
|
|
114
|
+
"type": "address"
|
|
115
|
+
},
|
|
116
|
+
{
|
|
117
|
+
"internalType": "address",
|
|
118
|
+
"name": "market",
|
|
119
|
+
"type": "address"
|
|
120
|
+
},
|
|
121
|
+
{
|
|
122
|
+
"internalType": "uint256",
|
|
123
|
+
"name": "exactYtIn",
|
|
124
|
+
"type": "uint256"
|
|
125
|
+
},
|
|
126
|
+
{
|
|
127
|
+
"internalType": "uint256",
|
|
128
|
+
"name": "minPtOut",
|
|
129
|
+
"type": "uint256"
|
|
130
|
+
},
|
|
131
|
+
{
|
|
132
|
+
"components": [
|
|
133
|
+
{
|
|
134
|
+
"internalType": "uint256",
|
|
135
|
+
"name": "guessMin",
|
|
136
|
+
"type": "uint256"
|
|
137
|
+
},
|
|
138
|
+
{
|
|
139
|
+
"internalType": "uint256",
|
|
140
|
+
"name": "guessMax",
|
|
141
|
+
"type": "uint256"
|
|
142
|
+
},
|
|
143
|
+
{
|
|
144
|
+
"internalType": "uint256",
|
|
145
|
+
"name": "guessOffchain",
|
|
146
|
+
"type": "uint256"
|
|
147
|
+
},
|
|
148
|
+
{
|
|
149
|
+
"internalType": "uint256",
|
|
150
|
+
"name": "maxIteration",
|
|
151
|
+
"type": "uint256"
|
|
152
|
+
},
|
|
153
|
+
{
|
|
154
|
+
"internalType": "uint256",
|
|
155
|
+
"name": "eps",
|
|
156
|
+
"type": "uint256"
|
|
157
|
+
}
|
|
158
|
+
],
|
|
159
|
+
"internalType": "struct ApproxParams",
|
|
160
|
+
"name": "guessTotalPtSwapped",
|
|
161
|
+
"type": "tuple"
|
|
162
|
+
}
|
|
163
|
+
],
|
|
164
|
+
"name": "swapExactYtForPt",
|
|
165
|
+
"outputs": [
|
|
166
|
+
{
|
|
167
|
+
"internalType": "uint256",
|
|
168
|
+
"name": "netPtOut",
|
|
169
|
+
"type": "uint256"
|
|
170
|
+
}
|
|
171
|
+
],
|
|
172
|
+
"stateMutability": "nonpayable",
|
|
173
|
+
"type": "function"
|
|
174
|
+
}
|
|
175
|
+
],
|
|
176
|
+
"bytecode": "0x",
|
|
177
|
+
"deployedBytecode": "0x",
|
|
178
|
+
"linkReferences": {},
|
|
179
|
+
"deployedLinkReferences": {}
|
|
180
|
+
}
|
|
@@ -845,6 +845,43 @@
|
|
|
845
845
|
"name": "SwapPtAndToken",
|
|
846
846
|
"type": "event"
|
|
847
847
|
},
|
|
848
|
+
{
|
|
849
|
+
"anonymous": false,
|
|
850
|
+
"inputs": [
|
|
851
|
+
{
|
|
852
|
+
"indexed": true,
|
|
853
|
+
"internalType": "address",
|
|
854
|
+
"name": "caller",
|
|
855
|
+
"type": "address"
|
|
856
|
+
},
|
|
857
|
+
{
|
|
858
|
+
"indexed": true,
|
|
859
|
+
"internalType": "address",
|
|
860
|
+
"name": "market",
|
|
861
|
+
"type": "address"
|
|
862
|
+
},
|
|
863
|
+
{
|
|
864
|
+
"indexed": true,
|
|
865
|
+
"internalType": "address",
|
|
866
|
+
"name": "receiver",
|
|
867
|
+
"type": "address"
|
|
868
|
+
},
|
|
869
|
+
{
|
|
870
|
+
"indexed": false,
|
|
871
|
+
"internalType": "int256",
|
|
872
|
+
"name": "netPtToAccount",
|
|
873
|
+
"type": "int256"
|
|
874
|
+
},
|
|
875
|
+
{
|
|
876
|
+
"indexed": false,
|
|
877
|
+
"internalType": "int256",
|
|
878
|
+
"name": "netYtToAccount",
|
|
879
|
+
"type": "int256"
|
|
880
|
+
}
|
|
881
|
+
],
|
|
882
|
+
"name": "SwapPtAndYt",
|
|
883
|
+
"type": "event"
|
|
884
|
+
},
|
|
848
885
|
{
|
|
849
886
|
"anonymous": false,
|
|
850
887
|
"inputs": [
|
|
@@ -2025,6 +2062,72 @@
|
|
|
2025
2062
|
"stateMutability": "nonpayable",
|
|
2026
2063
|
"type": "function"
|
|
2027
2064
|
},
|
|
2065
|
+
{
|
|
2066
|
+
"inputs": [
|
|
2067
|
+
{
|
|
2068
|
+
"internalType": "address",
|
|
2069
|
+
"name": "receiver",
|
|
2070
|
+
"type": "address"
|
|
2071
|
+
},
|
|
2072
|
+
{
|
|
2073
|
+
"internalType": "address",
|
|
2074
|
+
"name": "market",
|
|
2075
|
+
"type": "address"
|
|
2076
|
+
},
|
|
2077
|
+
{
|
|
2078
|
+
"internalType": "uint256",
|
|
2079
|
+
"name": "exactPtIn",
|
|
2080
|
+
"type": "uint256"
|
|
2081
|
+
},
|
|
2082
|
+
{
|
|
2083
|
+
"internalType": "uint256",
|
|
2084
|
+
"name": "minYtOut",
|
|
2085
|
+
"type": "uint256"
|
|
2086
|
+
},
|
|
2087
|
+
{
|
|
2088
|
+
"components": [
|
|
2089
|
+
{
|
|
2090
|
+
"internalType": "uint256",
|
|
2091
|
+
"name": "guessMin",
|
|
2092
|
+
"type": "uint256"
|
|
2093
|
+
},
|
|
2094
|
+
{
|
|
2095
|
+
"internalType": "uint256",
|
|
2096
|
+
"name": "guessMax",
|
|
2097
|
+
"type": "uint256"
|
|
2098
|
+
},
|
|
2099
|
+
{
|
|
2100
|
+
"internalType": "uint256",
|
|
2101
|
+
"name": "guessOffchain",
|
|
2102
|
+
"type": "uint256"
|
|
2103
|
+
},
|
|
2104
|
+
{
|
|
2105
|
+
"internalType": "uint256",
|
|
2106
|
+
"name": "maxIteration",
|
|
2107
|
+
"type": "uint256"
|
|
2108
|
+
},
|
|
2109
|
+
{
|
|
2110
|
+
"internalType": "uint256",
|
|
2111
|
+
"name": "eps",
|
|
2112
|
+
"type": "uint256"
|
|
2113
|
+
}
|
|
2114
|
+
],
|
|
2115
|
+
"internalType": "struct ApproxParams",
|
|
2116
|
+
"name": "guessTotalPtToSwap",
|
|
2117
|
+
"type": "tuple"
|
|
2118
|
+
}
|
|
2119
|
+
],
|
|
2120
|
+
"name": "swapExactPtForYt",
|
|
2121
|
+
"outputs": [
|
|
2122
|
+
{
|
|
2123
|
+
"internalType": "uint256",
|
|
2124
|
+
"name": "netYtOut",
|
|
2125
|
+
"type": "uint256"
|
|
2126
|
+
}
|
|
2127
|
+
],
|
|
2128
|
+
"stateMutability": "nonpayable",
|
|
2129
|
+
"type": "function"
|
|
2130
|
+
},
|
|
2028
2131
|
{
|
|
2029
2132
|
"inputs": [
|
|
2030
2133
|
{
|
|
@@ -2333,6 +2436,72 @@
|
|
|
2333
2436
|
"stateMutability": "payable",
|
|
2334
2437
|
"type": "function"
|
|
2335
2438
|
},
|
|
2439
|
+
{
|
|
2440
|
+
"inputs": [
|
|
2441
|
+
{
|
|
2442
|
+
"internalType": "address",
|
|
2443
|
+
"name": "receiver",
|
|
2444
|
+
"type": "address"
|
|
2445
|
+
},
|
|
2446
|
+
{
|
|
2447
|
+
"internalType": "address",
|
|
2448
|
+
"name": "market",
|
|
2449
|
+
"type": "address"
|
|
2450
|
+
},
|
|
2451
|
+
{
|
|
2452
|
+
"internalType": "uint256",
|
|
2453
|
+
"name": "exactYtIn",
|
|
2454
|
+
"type": "uint256"
|
|
2455
|
+
},
|
|
2456
|
+
{
|
|
2457
|
+
"internalType": "uint256",
|
|
2458
|
+
"name": "minPtOut",
|
|
2459
|
+
"type": "uint256"
|
|
2460
|
+
},
|
|
2461
|
+
{
|
|
2462
|
+
"components": [
|
|
2463
|
+
{
|
|
2464
|
+
"internalType": "uint256",
|
|
2465
|
+
"name": "guessMin",
|
|
2466
|
+
"type": "uint256"
|
|
2467
|
+
},
|
|
2468
|
+
{
|
|
2469
|
+
"internalType": "uint256",
|
|
2470
|
+
"name": "guessMax",
|
|
2471
|
+
"type": "uint256"
|
|
2472
|
+
},
|
|
2473
|
+
{
|
|
2474
|
+
"internalType": "uint256",
|
|
2475
|
+
"name": "guessOffchain",
|
|
2476
|
+
"type": "uint256"
|
|
2477
|
+
},
|
|
2478
|
+
{
|
|
2479
|
+
"internalType": "uint256",
|
|
2480
|
+
"name": "maxIteration",
|
|
2481
|
+
"type": "uint256"
|
|
2482
|
+
},
|
|
2483
|
+
{
|
|
2484
|
+
"internalType": "uint256",
|
|
2485
|
+
"name": "eps",
|
|
2486
|
+
"type": "uint256"
|
|
2487
|
+
}
|
|
2488
|
+
],
|
|
2489
|
+
"internalType": "struct ApproxParams",
|
|
2490
|
+
"name": "guessTotalPtSwapped",
|
|
2491
|
+
"type": "tuple"
|
|
2492
|
+
}
|
|
2493
|
+
],
|
|
2494
|
+
"name": "swapExactYtForPt",
|
|
2495
|
+
"outputs": [
|
|
2496
|
+
{
|
|
2497
|
+
"internalType": "uint256",
|
|
2498
|
+
"name": "netPtOut",
|
|
2499
|
+
"type": "uint256"
|
|
2500
|
+
}
|
|
2501
|
+
],
|
|
2502
|
+
"stateMutability": "nonpayable",
|
|
2503
|
+
"type": "function"
|
|
2504
|
+
},
|
|
2336
2505
|
{
|
|
2337
2506
|
"inputs": [
|
|
2338
2507
|
{
|
|
@@ -97,6 +97,25 @@
|
|
|
97
97
|
"name": "Withdraw",
|
|
98
98
|
"type": "event"
|
|
99
99
|
},
|
|
100
|
+
{
|
|
101
|
+
"inputs": [
|
|
102
|
+
{
|
|
103
|
+
"internalType": "address",
|
|
104
|
+
"name": "user",
|
|
105
|
+
"type": "address"
|
|
106
|
+
}
|
|
107
|
+
],
|
|
108
|
+
"name": "balanceOf",
|
|
109
|
+
"outputs": [
|
|
110
|
+
{
|
|
111
|
+
"internalType": "uint128",
|
|
112
|
+
"name": "",
|
|
113
|
+
"type": "uint128"
|
|
114
|
+
}
|
|
115
|
+
],
|
|
116
|
+
"stateMutability": "view",
|
|
117
|
+
"type": "function"
|
|
118
|
+
},
|
|
100
119
|
{
|
|
101
120
|
"inputs": [
|
|
102
121
|
{
|
|
@@ -121,6 +140,80 @@
|
|
|
121
140
|
"stateMutability": "nonpayable",
|
|
122
141
|
"type": "function"
|
|
123
142
|
},
|
|
143
|
+
{
|
|
144
|
+
"inputs": [
|
|
145
|
+
{
|
|
146
|
+
"internalType": "address",
|
|
147
|
+
"name": "user",
|
|
148
|
+
"type": "address"
|
|
149
|
+
}
|
|
150
|
+
],
|
|
151
|
+
"name": "positionData",
|
|
152
|
+
"outputs": [
|
|
153
|
+
{
|
|
154
|
+
"internalType": "uint128",
|
|
155
|
+
"name": "amount",
|
|
156
|
+
"type": "uint128"
|
|
157
|
+
},
|
|
158
|
+
{
|
|
159
|
+
"internalType": "uint128",
|
|
160
|
+
"name": "expiry",
|
|
161
|
+
"type": "uint128"
|
|
162
|
+
}
|
|
163
|
+
],
|
|
164
|
+
"stateMutability": "view",
|
|
165
|
+
"type": "function"
|
|
166
|
+
},
|
|
167
|
+
{
|
|
168
|
+
"inputs": [
|
|
169
|
+
{
|
|
170
|
+
"internalType": "address",
|
|
171
|
+
"name": "user",
|
|
172
|
+
"type": "address"
|
|
173
|
+
}
|
|
174
|
+
],
|
|
175
|
+
"name": "totalSupplyAndBalanceCurrent",
|
|
176
|
+
"outputs": [
|
|
177
|
+
{
|
|
178
|
+
"internalType": "uint128",
|
|
179
|
+
"name": "",
|
|
180
|
+
"type": "uint128"
|
|
181
|
+
},
|
|
182
|
+
{
|
|
183
|
+
"internalType": "uint128",
|
|
184
|
+
"name": "",
|
|
185
|
+
"type": "uint128"
|
|
186
|
+
}
|
|
187
|
+
],
|
|
188
|
+
"stateMutability": "nonpayable",
|
|
189
|
+
"type": "function"
|
|
190
|
+
},
|
|
191
|
+
{
|
|
192
|
+
"inputs": [],
|
|
193
|
+
"name": "totalSupplyCurrent",
|
|
194
|
+
"outputs": [
|
|
195
|
+
{
|
|
196
|
+
"internalType": "uint128",
|
|
197
|
+
"name": "",
|
|
198
|
+
"type": "uint128"
|
|
199
|
+
}
|
|
200
|
+
],
|
|
201
|
+
"stateMutability": "nonpayable",
|
|
202
|
+
"type": "function"
|
|
203
|
+
},
|
|
204
|
+
{
|
|
205
|
+
"inputs": [],
|
|
206
|
+
"name": "totalSupplyStored",
|
|
207
|
+
"outputs": [
|
|
208
|
+
{
|
|
209
|
+
"internalType": "uint128",
|
|
210
|
+
"name": "",
|
|
211
|
+
"type": "uint128"
|
|
212
|
+
}
|
|
213
|
+
],
|
|
214
|
+
"stateMutability": "view",
|
|
215
|
+
"type": "function"
|
|
216
|
+
},
|
|
124
217
|
{
|
|
125
218
|
"inputs": [],
|
|
126
219
|
"name": "withdraw",
|
package/build/artifacts/contracts/libraries/math/MarketApproxLib.sol/MarketApproxPtInLib.json
CHANGED
|
@@ -3,8 +3,8 @@
|
|
|
3
3
|
"contractName": "MarketApproxPtInLib",
|
|
4
4
|
"sourceName": "contracts/libraries/math/MarketApproxLib.sol",
|
|
5
5
|
"abi": [],
|
|
6
|
-
"bytecode": "
|
|
7
|
-
"deployedBytecode": "
|
|
6
|
+
"bytecode": "0x60566037600b82828239805160001a607314602a57634e487b7160e01b600052600060045260246000fd5b30600052607381538281f3fe73000000000000000000000000000000000000000030146080604052600080fdfea264697066735822122033f4375c13c7eee31dbe5f54fcc1eb6ed81f44699eae0e35c44598235bf25a4f64736f6c634300080f0033",
|
|
7
|
+
"deployedBytecode": "0x73000000000000000000000000000000000000000030146080604052600080fdfea264697066735822122033f4375c13c7eee31dbe5f54fcc1eb6ed81f44699eae0e35c44598235bf25a4f64736f6c634300080f0033",
|
|
8
8
|
"linkReferences": {},
|
|
9
9
|
"deployedLinkReferences": {}
|
|
10
10
|
}
|
package/build/artifacts/contracts/libraries/math/MarketApproxLib.sol/MarketApproxPtOutLib.json
CHANGED
|
@@ -3,8 +3,8 @@
|
|
|
3
3
|
"contractName": "MarketApproxPtOutLib",
|
|
4
4
|
"sourceName": "contracts/libraries/math/MarketApproxLib.sol",
|
|
5
5
|
"abi": [],
|
|
6
|
-
"bytecode": "
|
|
7
|
-
"deployedBytecode": "
|
|
6
|
+
"bytecode": "0x60566037600b82828239805160001a607314602a57634e487b7160e01b600052600060045260246000fd5b30600052607381538281f3fe73000000000000000000000000000000000000000030146080604052600080fdfea2646970667358221220fee8dc80d193c3f6180361670a00a9207d33d759c197bf9a0ea031eebdfa741964736f6c634300080f0033",
|
|
7
|
+
"deployedBytecode": "0x73000000000000000000000000000000000000000030146080604052600080fdfea2646970667358221220fee8dc80d193c3f6180361670a00a9207d33d759c197bf9a0ea031eebdfa741964736f6c634300080f0033",
|
|
8
8
|
"linkReferences": {},
|
|
9
9
|
"deployedLinkReferences": {}
|
|
10
10
|
}
|