@pendle/core-v2 6.3.1 → 6.3.2-pendle-merkle-transfer
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/LiquidityMining/CrossChainMsg/PendleMsgReceiveEndpointUpg.sol/PendleMsgReceiveEndpointUpg.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/CrossChainMsg/PendleMsgReceiveEndpointUpg.sol/PendleMsgReceiveEndpointUpg.json +2 -2
- package/build/artifacts/contracts/LiquidityMining/CrossChainMsg/PendleMsgReceiverAppUpg.sol/PendleMsgReceiverAppUpg.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/CrossChainMsg/PendleMsgSendEndpointUpg.sol/PendleMsgSendEndpointUpg.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/CrossChainMsg/PendleMsgSendEndpointUpg.sol/PendleMsgSendEndpointUpg.json +2 -2
- package/build/artifacts/contracts/LiquidityMining/CrossChainMsg/PendleMsgSenderAppUpg.sol/PendleMsgSenderAppUpg.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/CrossChainMsg/libraries/ExcessivelySafeCall.sol/ExcessivelySafeCall.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/CrossChainMsg/libraries/ExcessivelySafeCall.sol/ExcessivelySafeCall.json +2 -2
- package/build/artifacts/contracts/LiquidityMining/CrossChainMsg/libraries/LayerZeroHelper.sol/LayerZeroHelper.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/CrossChainMsg/libraries/LayerZeroHelper.sol/LayerZeroHelper.json +2 -2
- package/build/artifacts/contracts/LiquidityMining/GaugeController/PendleGaugeControllerBaseUpg.sol/PendleGaugeControllerBaseUpg.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/GaugeController/PendleGaugeControllerMainchainUpg.sol/PendleGaugeControllerMainchainUpg.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/GaugeController/PendleGaugeControllerMainchainUpg.sol/PendleGaugeControllerMainchainUpg.json +2 -2
- package/build/artifacts/contracts/LiquidityMining/GaugeController/PendleGaugeControllerSidechainUpg.sol/PendleGaugeControllerSidechainUpg.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/GaugeController/PendleGaugeControllerSidechainUpg.sol/PendleGaugeControllerSidechainUpg.json +2 -2
- package/build/artifacts/contracts/LiquidityMining/PendleMerkleDistributor.sol/PendleMerkleDistributor.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/PendleMerkleDistributor.sol/PendleMerkleDistributor.json +2 -2
- package/build/artifacts/contracts/LiquidityMining/PendleMultiTokenMerkleDistributor.sol/PendleMultiTokenMerkleDistributor.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/PendleMultiTokenMerkleDistributor.sol/PendleMultiTokenMerkleDistributor.json +2 -2
- package/build/artifacts/contracts/LiquidityMining/VotingController/PendleVotingControllerUpg.sol/PendleVotingControllerUpg.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/VotingController/PendleVotingControllerUpg.sol/PendleVotingControllerUpg.json +2 -2
- package/build/artifacts/contracts/LiquidityMining/VotingController/VotingControllerStorageUpg.sol/VotingControllerStorageUpg.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/VotingEscrow/VotingEscrowPendleMainchain.sol/VotingEscrowPendleMainchain.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/VotingEscrow/VotingEscrowPendleMainchain.sol/VotingEscrowPendleMainchain.json +2 -2
- package/build/artifacts/contracts/LiquidityMining/VotingEscrow/VotingEscrowPendleSidechain.sol/VotingEscrowPendleSidechain.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/VotingEscrow/VotingEscrowPendleSidechain.sol/VotingEscrowPendleSidechain.json +2 -2
- package/build/artifacts/contracts/LiquidityMining/VotingEscrow/VotingEscrowTokenBase.sol/VotingEscrowTokenBase.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/libraries/VeBalanceLib.sol/VeBalanceLib.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/libraries/VeBalanceLib.sol/VeBalanceLib.json +2 -2
- package/build/artifacts/contracts/LiquidityMining/libraries/VeHistoryLib.sol/CheckpointHelper.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/libraries/VeHistoryLib.sol/CheckpointHelper.json +2 -2
- package/build/artifacts/contracts/LiquidityMining/libraries/VeHistoryLib.sol/Checkpoints.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/libraries/VeHistoryLib.sol/Checkpoints.json +2 -2
- package/build/artifacts/contracts/core/Market/MarketMathCore.sol/MarketMathCore.dbg.json +1 -1
- package/build/artifacts/contracts/core/Market/MarketMathCore.sol/MarketMathCore.json +2 -2
- package/build/artifacts/contracts/core/Market/OracleLib.sol/OracleLib.dbg.json +1 -1
- package/build/artifacts/contracts/core/Market/OracleLib.sol/OracleLib.json +2 -2
- package/build/artifacts/contracts/core/Market/PendleGauge.sol/PendleGauge.dbg.json +1 -1
- package/build/artifacts/contracts/core/Market/PendleMarketFactoryV6Upg.sol/PendleMarketFactoryV6Upg.dbg.json +1 -1
- package/build/artifacts/contracts/core/Market/PendleMarketFactoryV6Upg.sol/PendleMarketFactoryV6Upg.json +2 -2
- package/build/artifacts/contracts/core/Market/PendleMarketV6.sol/PendleMarketV6.dbg.json +1 -1
- package/build/artifacts/contracts/core/Market/PendleMarketV6.sol/PendleMarketV6.json +2 -2
- package/build/artifacts/contracts/core/RewardManager/RewardManager.sol/RewardManager.dbg.json +1 -1
- package/build/artifacts/contracts/core/RewardManager/RewardManagerAbstract.sol/RewardManagerAbstract.dbg.json +1 -1
- package/build/artifacts/contracts/core/StandardizedYield/PYIndex.sol/PYIndexLib.dbg.json +1 -1
- package/build/artifacts/contracts/core/StandardizedYield/PYIndex.sol/PYIndexLib.json +2 -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/PendlePrincipalToken.sol/PendlePrincipalToken.json +2 -2
- package/build/artifacts/contracts/core/YieldContracts/PendleYieldContractFactoryUpg.sol/PendleYieldContractFactoryUpg.dbg.json +1 -1
- package/build/artifacts/contracts/core/YieldContracts/PendleYieldContractFactoryUpg.sol/PendleYieldContractFactoryUpg.json +2 -2
- package/build/artifacts/contracts/core/YieldContracts/PendleYieldToken.sol/PendleYieldToken.dbg.json +1 -1
- package/build/artifacts/contracts/core/YieldContracts/PendleYieldToken.sol/PendleYieldToken.json +2 -2
- package/build/artifacts/contracts/core/erc20/PendleERC20.sol/PendleERC20.dbg.json +1 -1
- package/build/artifacts/contracts/core/erc20/PendleERC20.sol/PendleERC20.json +2 -2
- package/build/artifacts/contracts/core/libraries/ArrayLib.sol/ArrayLib.dbg.json +1 -1
- package/build/artifacts/contracts/core/libraries/ArrayLib.sol/ArrayLib.json +2 -2
- package/build/artifacts/contracts/core/libraries/BaseSplitCodeFactory.sol/BaseSplitCodeFactory.dbg.json +1 -1
- package/build/artifacts/contracts/core/libraries/BaseSplitCodeFactory.sol/BaseSplitCodeFactory.json +2 -2
- package/build/artifacts/contracts/core/libraries/BaseSplitCodeFactory.sol/CodeDeployer.dbg.json +1 -1
- package/build/artifacts/contracts/core/libraries/BaseSplitCodeFactory.sol/CodeDeployer.json +2 -2
- package/build/artifacts/contracts/core/libraries/BoringOwnableUpgradeableV2.sol/BoringOwnableUpgradeableData.dbg.json +1 -1
- package/build/artifacts/contracts/core/libraries/BoringOwnableUpgradeableV2.sol/BoringOwnableUpgradeableData.json +2 -2
- package/build/artifacts/contracts/core/libraries/BoringOwnableUpgradeableV2.sol/BoringOwnableUpgradeableV2.dbg.json +1 -1
- package/build/artifacts/contracts/core/libraries/Errors.sol/Errors.dbg.json +1 -1
- package/build/artifacts/contracts/core/libraries/Errors.sol/Errors.json +2 -2
- package/build/artifacts/contracts/core/libraries/ExpiryUtilsLib.sol/ExpiryUtils.dbg.json +1 -1
- package/build/artifacts/contracts/core/libraries/ExpiryUtilsLib.sol/ExpiryUtils.json +2 -2
- package/build/artifacts/contracts/core/libraries/StringLib.sol/StringLib.dbg.json +1 -1
- package/build/artifacts/contracts/core/libraries/StringLib.sol/StringLib.json +2 -2
- package/build/artifacts/contracts/core/libraries/TokenHelper.sol/TokenHelper.dbg.json +1 -1
- package/build/artifacts/contracts/core/libraries/math/LogExpMath.sol/LogExpMath.dbg.json +1 -1
- package/build/artifacts/contracts/core/libraries/math/LogExpMath.sol/LogExpMath.json +2 -2
- package/build/artifacts/contracts/cross-chain/FixedPricePTAMM.sol/FixedPricePTAMM.dbg.json +1 -1
- package/build/artifacts/contracts/cross-chain/FixedPricePTAMM.sol/FixedPricePTAMM.json +2 -2
- package/build/artifacts/contracts/cross-chain/factory/hub/PendlePTOFTAdapterFactory.sol/PendlePTOFTAdapterFactory.dbg.json +1 -1
- package/build/artifacts/contracts/cross-chain/factory/hub/PendlePTOFTAdapterFactory.sol/PendlePTOFTAdapterFactory.json +2 -2
- package/build/artifacts/contracts/cross-chain/oftImpl/spoke/PendleBridgedPrincipalToken.sol/PendleBridgedPrincipalToken.dbg.json +1 -1
- package/build/artifacts/contracts/cross-chain/oftImpl/spoke/PendleBridgedPrincipalToken.sol/PendleBridgedPrincipalToken.json +2 -2
- package/build/artifacts/contracts/deprecated/VeDistributor/PendleFeeDistributor.sol/PendleFeeDistributor.dbg.json +1 -1
- package/build/artifacts/contracts/deprecated/VeDistributor/PendleFeeDistributor.sol/PendleFeeDistributor.json +2 -2
- package/build/artifacts/contracts/deprecated/VeDistributor/PendleFeeDistributorV2.sol/PendleFeeDistributorV2.dbg.json +1 -1
- package/build/artifacts/contracts/deprecated/VeDistributor/PendleFeeDistributorV2.sol/PendleFeeDistributorV2.json +2 -2
- package/build/artifacts/contracts/interfaces/ILayerZeroEndpoint.sol/ILayerZeroEndpoint.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPActionAddRemoveLiqV3.sol/IPActionAddRemoveLiqV3.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPActionCallbackV3.sol/IPActionCallbackV3.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPActionInfoStatic.sol/IPActionInfoStatic.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPActionMarketAuxStatic.sol/IPActionMarketAuxStatic.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPActionMarketCoreStatic.sol/IPActionMarketCoreStatic.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPActionMintRedeemStatic.sol/IPActionMintRedeemStatic.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPActionMiscV3.sol/IPActionMiscV3.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPActionSimple.sol/IPActionSimple.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPActionStorageStatic.sol/IPActionStorageStatic.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPActionStorageV4.sol/IPActionStorageV4.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPActionSwapPTV3.sol/IPActionSwapPTV3.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPActionSwapYTV3.sol/IPActionSwapYTV3.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPActionVePendleStatic.sol/IPActionVePendleStatic.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPAllActionV3.sol/IPAllActionV3.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPAllEventsV3.sol/IPActionAddRemoveLiqV3Events.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPAllEventsV3.sol/IPActionMiscV3Events.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPAllEventsV3.sol/IPActionStorageEvents.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPAllEventsV3.sol/IPActionSwapPTV3Events.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPAllEventsV3.sol/IPActionSwapYTV3Events.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPAllEventsV3.sol/IPAllEventsV3.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPBridgedPrincipalToken.sol/IPBridgedPrincipalToken.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPCommonSYFactory.sol/IPCommonSYFactory.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPExchangeRateOracleApp.sol/IPExchangeRateOracleApp.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPFeeDistributorV2.sol/IPFeeDistributorV2.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPFixedPricePTAMM.sol/IPFixedPricePTAMM.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPFixedPricePTAMM.sol/IPFixedPricePTAMMSwapCallback.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPGovernanceProxy.sol/IPGovernanceProxy.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPInterestManagerYTV2.sol/IPInterestManagerYTV2.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPLimitRouter.sol/IPLimitOrderType.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPLimitRouter.sol/IPLimitRouter.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPLimitRouter.sol/IPLimitRouter.json +0 -42
- package/build/artifacts/contracts/interfaces/IPLimitRouter.sol/IPLimitRouterCallback.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPMarket.sol/IPMarket.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPMarket.sol/IPMarket.json +0 -13
- package/build/artifacts/contracts/interfaces/IPMarketFactory.sol/IPMarketFactory.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPMerkleDistributor.sol/IPMerkleDistributor.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPMsgSendEndpoint.sol/IPMsgSendEndpoint.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPMultiTokenMerkleDistributor.sol/IPMultiTokenMerkleDistributor.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPPYLpOracle.sol/IPPYLpOracle.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPRouterStatic.sol/IPRouterStatic.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPVotingController.sol/IPVotingController.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPVotingEscrowMainchain.sol/IPVotingEscrowMainchain.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPYieldContractFactory.sol/IPYieldContractFactory.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPYieldToken.sol/IPYieldToken.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPYieldTokenV2.sol/IPYieldTokenV2.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IStandardizedYield.sol/IStandardizedYield.dbg.json +1 -1
- package/build/artifacts/contracts/limit/LimitMathCore.sol/LimitMathCore.dbg.json +1 -1
- package/build/artifacts/contracts/limit/LimitMathCore.sol/LimitMathCore.json +2 -2
- package/build/artifacts/contracts/limit/LimitRouterBase.sol/LimitRouterBase.dbg.json +1 -1
- package/build/artifacts/contracts/limit/PendleLimitRouter.sol/PendleLimitRouter.dbg.json +1 -1
- package/build/artifacts/contracts/limit/PendleLimitRouter.sol/PendleLimitRouter.json +2 -2
- package/build/artifacts/contracts/offchain-helpers/AddressProvider.sol/AddressProvider.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/AddressProvider.sol/AddressProvider.json +2 -2
- package/build/artifacts/contracts/offchain-helpers/AutomateReady.sol/AutomateReady.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/AutomateReady.sol/IAutomate.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/AutomateReady.sol/IOpsProxyFactory.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/AutomateReady.sol/ITaskTreasuryUpgradable.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/BalanceReader.sol/BalanceReader.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/BalanceReader.sol/BalanceReader.json +2 -2
- package/build/artifacts/contracts/offchain-helpers/BaseSplitCodeFactoryContract.sol/BaseSplitCodeFactoryContract.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/BaseSplitCodeFactoryContract.sol/BaseSplitCodeFactoryContract.json +2 -2
- package/build/artifacts/contracts/offchain-helpers/Broadcaster.sol/Broadcaster.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/Broadcaster.sol/Broadcaster.json +2 -2
- package/build/artifacts/contracts/offchain-helpers/BytesLib.sol/BytesLib.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/BytesLib.sol/BytesLib.json +2 -2
- package/build/artifacts/contracts/offchain-helpers/EmptyUUPS.sol/EmptyUUPS.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/EmptyUUPS.sol/EmptyUUPS.json +2 -2
- package/build/artifacts/contracts/offchain-helpers/ExpiredLpPtRedeemer.sol/ExpiredLpPtRedeemer.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/ExpiredLpPtRedeemer.sol/ExpiredLpPtRedeemer.json +2 -2
- package/build/artifacts/contracts/offchain-helpers/LegacyNFTHelper.sol/LegacyNFTHelper.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/LegacyNFTHelper.sol/LegacyNFTHelper.json +2 -2
- package/build/artifacts/contracts/offchain-helpers/LegacyNFTHelper.sol/StarNFTV1.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/LimitBackendHelperV2.sol/LimitBackendHelperV2.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/LimitBackendHelperV2.sol/LimitBackendHelperV2.json +2 -2
- package/build/artifacts/contracts/offchain-helpers/Multicall2.sol/Multicall2.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/Multicall2.sol/Multicall2.json +2 -2
- package/build/artifacts/contracts/offchain-helpers/PendleExchangeRateOracle.sol/PendleExchangeRateOracle.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/PendleExchangeRateOracle.sol/PendleExchangeRateOracle.json +2 -2
- package/build/artifacts/contracts/offchain-helpers/PendleGovernanceProxy.sol/PendleGovernanceProxy.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/PendleGovernanceProxy.sol/PendleGovernanceProxy.json +2 -2
- package/build/artifacts/contracts/offchain-helpers/PendleLPWrapper.sol/PendleLPWrapper.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/PendleLPWrapper.sol/PendleLPWrapper.json +2 -2
- package/build/artifacts/contracts/offchain-helpers/PendleLPWrapperFactory.sol/PendleLPWrapperFactory.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/PendleLPWrapperFactory.sol/PendleLPWrapperFactory.json +2 -2
- package/build/artifacts/contracts/offchain-helpers/PendleMerkleDepositor.sol/PendleMerkleDepositor.dbg.json +4 -0
- package/build/artifacts/contracts/offchain-helpers/PendleMerkleDepositor.sol/PendleMerkleDepositor.json +102 -0
- package/build/artifacts/contracts/offchain-helpers/PendleMulticallOwnerV1.sol/PendleMulticallOwnerV1.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/PendleMulticallOwnerV1.sol/PendleMulticallOwnerV1.json +2 -2
- package/build/artifacts/contracts/offchain-helpers/PendleMulticallV1.sol/PendleMulticallV1.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/PendleMulticallV1.sol/PendleMulticallV1.json +2 -2
- package/build/artifacts/contracts/offchain-helpers/PendleMulticallV2.sol/PendleMulticallV2.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/PendleMulticallV2.sol/PendleMulticallV2.json +2 -2
- package/build/artifacts/contracts/offchain-helpers/PendleOffchainStorage.sol/PendleOffchainStorage.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/PendleOffchainStorage.sol/PendleOffchainStorage.json +2 -2
- package/build/artifacts/contracts/offchain-helpers/PendleWstETHPriceFeed.sol/PendleWstETHPriceFeed.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/PendleWstETHPriceFeed.sol/PendleWstETHPriceFeed.json +2 -2
- package/build/artifacts/contracts/offchain-helpers/SimulateHelper.sol/SimulateHelper.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/SimulateHelper.sol/SimulateHelper.json +2 -2
- package/build/artifacts/contracts/offchain-helpers/deploy/PendleCommonPoolDeployHelperV2.sol/PendleCommonPoolDeployHelperV2.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/deploy/PendleCommonPoolDeployHelperV2.sol/PendleCommonPoolDeployHelperV2.json +2 -2
- package/build/artifacts/contracts/offchain-helpers/deploy/PendleCommonSYFactory.sol/PendleCommonSYFactory.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/deploy/PendleCommonSYFactory.sol/PendleCommonSYFactory.json +2 -2
- package/build/artifacts/contracts/offchain-helpers/deploy/PendlePoolDeployHelper.sol/PendlePoolDeployHelper.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/deploy/PendlePoolDeployHelper.sol/PendlePoolDeployHelper.json +2 -2
- package/build/artifacts/contracts/offchain-helpers/deploy/PendlePoolDeployHelperV2.sol/PendlePoolDeployHelperV2.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/deploy/PendlePoolDeployHelperV2.sol/PendlePoolDeployHelperV2.json +2 -2
- package/build/artifacts/contracts/offchain-helpers/deploy/lib/MarketDeployLib.sol/MarketDeployLib.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/deploy/lib/MarketDeployLib.sol/MarketDeployLib.json +2 -2
- package/build/artifacts/contracts/offchain-helpers/errors/SDKErrorsDirectory.sol/SDKErrorsDirectory.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/errors/SDKErrorsDirectory.sol/SDKErrorsDirectory.json +2 -2
- package/build/artifacts/contracts/offchain-helpers/router-static/PendleRouterStatic.sol/PendleRouterStatic.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/router-static/PendleRouterStatic.sol/PendleRouterStatic.json +2 -2
- package/build/artifacts/contracts/offchain-helpers/router-static/base/ActionInfoStatic.sol/ActionInfoStatic.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/router-static/base/ActionInfoStatic.sol/ActionInfoStatic.json +2 -2
- package/build/artifacts/contracts/offchain-helpers/router-static/base/ActionMarketAuxStatic.sol/ActionMarketAuxStatic.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/router-static/base/ActionMarketAuxStatic.sol/ActionMarketAuxStatic.json +2 -2
- package/build/artifacts/contracts/offchain-helpers/router-static/base/ActionMarketCoreStatic.sol/ActionMarketCoreStatic.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/router-static/base/ActionMarketCoreStatic.sol/ActionMarketCoreStatic.json +2 -2
- package/build/artifacts/contracts/offchain-helpers/router-static/base/ActionMintRedeemStatic.sol/ActionMintRedeemStatic.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/router-static/base/ActionMintRedeemStatic.sol/ActionMintRedeemStatic.json +2 -2
- package/build/artifacts/contracts/offchain-helpers/router-static/base/ActionStorageStatic.sol/ActionStorageStatic.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/router-static/base/ActionStorageStatic.sol/ActionStorageStatic.json +2 -2
- package/build/artifacts/contracts/offchain-helpers/router-static/base/ActionVePendleStatic.sol/ActionVePendleStatic.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/router-static/base/ActionVePendleStatic.sol/ActionVePendleStatic.json +2 -2
- package/build/artifacts/contracts/offchain-helpers/router-static/base/MarketApproxLibV1.sol/MarketApproxPtInLibV1.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/router-static/base/MarketApproxLibV1.sol/MarketApproxPtInLibV1.json +2 -2
- package/build/artifacts/contracts/offchain-helpers/router-static/base/MarketApproxLibV1.sol/MarketApproxPtOutLibV1.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/router-static/base/MarketApproxLibV1.sol/MarketApproxPtOutLibV1.json +2 -2
- package/build/artifacts/contracts/offchain-helpers/router-static/base/StorageLayout.sol/StorageLayout.dbg.json +1 -1
- package/build/artifacts/contracts/oracles/CrossChainOracle/base/PendleCrossChainOracleBaseApp_Init.sol/PendleCrossChainOracleBaseApp_Init.dbg.json +1 -1
- package/build/artifacts/contracts/oracles/CrossChainOracle/exchangeRate/PendleExchangeRateOracleApp.sol/PendleExchangeRateOracleApp.dbg.json +1 -1
- package/build/artifacts/contracts/oracles/CrossChainOracle/exchangeRate/PendleExchangeRateOracleApp.sol/PendleExchangeRateOracleApp.json +2 -2
- package/build/artifacts/contracts/oracles/CrossChainOracle/exchangeRate/PendleExchangeRateOracleV2.sol/PendleExchangeRateOracleV2.dbg.json +1 -1
- package/build/artifacts/contracts/oracles/CrossChainOracle/exchangeRate/PendleExchangeRateOracleV2.sol/PendleExchangeRateOracleV2.json +2 -2
- package/build/artifacts/contracts/oracles/CrossChainOracle/libraries/ExchangeRateMsgCodec.sol/ExchangeRateMsgCodec.dbg.json +1 -1
- package/build/artifacts/contracts/oracles/CrossChainOracle/libraries/ExchangeRateMsgCodec.sol/ExchangeRateMsgCodec.json +2 -2
- package/build/artifacts/contracts/oracles/PtYtLpOracle/PendleLpOracleLib.sol/PendleLpOracleLib.dbg.json +1 -1
- package/build/artifacts/contracts/oracles/PtYtLpOracle/PendleLpOracleLib.sol/PendleLpOracleLib.json +2 -2
- package/build/artifacts/contracts/oracles/PtYtLpOracle/PendlePYLpOracle.sol/PendlePYLpOracle.dbg.json +1 -1
- package/build/artifacts/contracts/oracles/PtYtLpOracle/PendlePYLpOracle.sol/PendlePYLpOracle.json +2 -2
- package/build/artifacts/contracts/oracles/PtYtLpOracle/PendlePYOracleLib.sol/PendlePYOracleLib.dbg.json +1 -1
- package/build/artifacts/contracts/oracles/PtYtLpOracle/PendlePYOracleLib.sol/PendlePYOracleLib.json +2 -2
- package/build/artifacts/contracts/oracles/PtYtLpOracle/chainlink/PendleChainlinkOracle.sol/PendleChainlinkOracle.dbg.json +1 -1
- package/build/artifacts/contracts/oracles/PtYtLpOracle/chainlink/PendleChainlinkOracle.sol/PendleChainlinkOracle.json +2 -2
- package/build/artifacts/contracts/oracles/PtYtLpOracle/chainlink/PendleChainlinkOracleFactory.sol/PendleChainlinkOracleFactory.dbg.json +1 -1
- package/build/artifacts/contracts/oracles/PtYtLpOracle/chainlink/PendleChainlinkOracleFactory.sol/PendleChainlinkOracleFactory.json +2 -2
- package/build/artifacts/contracts/oracles/PtYtLpOracle/chainlink/PendleChainlinkOracleWithQuote.sol/PendleChainlinkOracleWithQuote.dbg.json +1 -1
- package/build/artifacts/contracts/oracles/PtYtLpOracle/chainlink/PendleChainlinkOracleWithQuote.sol/PendleChainlinkOracleWithQuote.json +2 -2
- package/build/artifacts/contracts/oracles/PtYtLpOracle/samples/BoringLpSeller.sol/BoringLpSeller.dbg.json +1 -1
- package/build/artifacts/contracts/oracles/PtYtLpOracle/samples/BoringPYUsdChainlinkAssetOracle.sol/BoringPYUsdChainlinkAssetOracle.dbg.json +1 -1
- package/build/artifacts/contracts/oracles/PtYtLpOracle/samples/BoringPYUsdChainlinkAssetOracle.sol/BoringPYUsdChainlinkAssetOracle.json +2 -2
- package/build/artifacts/contracts/oracles/PtYtLpOracle/samples/BoringPYUsdChainlinkSYOracle.sol/BoringPYUsdChainlinkSYOracle.dbg.json +1 -1
- package/build/artifacts/contracts/oracles/PtYtLpOracle/samples/BoringPYUsdChainlinkSYOracle.sol/BoringPYUsdChainlinkSYOracle.json +2 -2
- package/build/artifacts/contracts/oracles/PtYtLpOracle/samples/BoringPtSeller.sol/BoringPtSeller.dbg.json +1 -1
- package/build/artifacts/contracts/oracles/StatelessWrapper/PendleSparkLinearDiscountOracleFactoryWrapper.sol/PendleSparkLinearDiscountOracleFactoryWrapper.dbg.json +1 -1
- package/build/artifacts/contracts/oracles/StatelessWrapper/PendleSparkLinearDiscountOracleFactoryWrapper.sol/PendleSparkLinearDiscountOracleFactoryWrapper.json +2 -2
- package/build/artifacts/contracts/oracles/internal/PendleSparkLinearDiscountOracleFactory.sol/PendleSparkLinearDiscountOracleFactory.dbg.json +1 -1
- package/build/artifacts/contracts/oracles/internal/PendleSparkLinearDiscountOracleFactory.sol/PendleSparkLinearDiscountOracleFactory.json +2 -2
- package/build/artifacts/contracts/router/ActionAddRemoveLiqV3.sol/ActionAddRemoveLiqV3.dbg.json +1 -1
- package/build/artifacts/contracts/router/ActionAddRemoveLiqV3.sol/ActionAddRemoveLiqV3.json +2 -2
- package/build/artifacts/contracts/router/ActionCallbackV3.sol/ActionCallbackV3.dbg.json +1 -1
- package/build/artifacts/contracts/router/ActionCallbackV3.sol/ActionCallbackV3.json +2 -2
- package/build/artifacts/contracts/router/ActionMiscV3.sol/ActionMiscV3.dbg.json +1 -1
- package/build/artifacts/contracts/router/ActionMiscV3.sol/ActionMiscV3.json +2 -2
- package/build/artifacts/contracts/router/ActionSimple.sol/ActionSimple.dbg.json +1 -1
- package/build/artifacts/contracts/router/ActionSimple.sol/ActionSimple.json +2 -2
- package/build/artifacts/contracts/router/ActionStorageV4.sol/ActionStorageV4.dbg.json +1 -1
- package/build/artifacts/contracts/router/ActionStorageV4.sol/ActionStorageV4.json +2 -2
- package/build/artifacts/contracts/router/ActionSwapPTV3.sol/ActionSwapPTV3.dbg.json +1 -1
- package/build/artifacts/contracts/router/ActionSwapPTV3.sol/ActionSwapPTV3.json +2 -2
- package/build/artifacts/contracts/router/ActionSwapYTV3.sol/ActionSwapYTV3.dbg.json +1 -1
- package/build/artifacts/contracts/router/ActionSwapYTV3.sol/ActionSwapYTV3.json +2 -2
- package/build/artifacts/contracts/router/PendleRouterV4.sol/PendleRouterV4.dbg.json +1 -1
- package/build/artifacts/contracts/router/PendleRouterV4.sol/PendleRouterV4.json +2 -2
- package/build/artifacts/contracts/router/Reflector.sol/Reflector.dbg.json +1 -1
- package/build/artifacts/contracts/router/Reflector.sol/Reflector.json +2 -2
- package/build/artifacts/contracts/router/base/ActionBase.sol/ActionBase.dbg.json +1 -1
- package/build/artifacts/contracts/router/base/ActionDelegateBase.sol/ActionDelegateBase.dbg.json +1 -1
- package/build/artifacts/contracts/router/base/ActionDelegateBase.sol/ActionDelegateBase.json +2 -2
- package/build/artifacts/contracts/router/base/CallbackHelper.sol/CallbackHelper.dbg.json +1 -1
- package/build/artifacts/contracts/router/math/ApproxStateLib.sol/ApproxStateLib.dbg.json +1 -1
- package/build/artifacts/contracts/router/math/ApproxStateLib.sol/ApproxStateLib.json +2 -2
- package/build/artifacts/contracts/router/math/MarketApproxEstimateLib.sol/MarketApproxEstimateLib.dbg.json +1 -1
- package/build/artifacts/contracts/router/math/MarketApproxEstimateLib.sol/MarketApproxEstimateLib.json +2 -2
- package/build/artifacts/contracts/router/math/MarketApproxLibOnchain.sol/MarketApproxPtInLibOnchain.dbg.json +1 -1
- package/build/artifacts/contracts/router/math/MarketApproxLibOnchain.sol/MarketApproxPtInLibOnchain.json +2 -2
- package/build/artifacts/contracts/router/math/MarketApproxLibOnchain.sol/MarketApproxPtOutLibOnchain.dbg.json +1 -1
- package/build/artifacts/contracts/router/math/MarketApproxLibOnchain.sol/MarketApproxPtOutLibOnchain.json +2 -2
- package/build/artifacts/contracts/router/math/MarketApproxLibV2.sol/MarketApproxPtInLibV2.dbg.json +1 -1
- package/build/artifacts/contracts/router/math/MarketApproxLibV2.sol/MarketApproxPtInLibV2.json +2 -2
- package/build/artifacts/contracts/router/math/MarketApproxLibV2.sol/MarketApproxPtOutLibV2.dbg.json +1 -1
- package/build/artifacts/contracts/router/math/MarketApproxLibV2.sol/MarketApproxPtOutLibV2.json +2 -2
- package/build/artifacts/contracts/router/swap-aggregator/OKXScaleHelper.sol/IOKXDexRouter.dbg.json +1 -1
- package/build/artifacts/contracts/router/swap-aggregator/OKXScaleHelper.sol/IOKXDexRouter.json +0 -171
- package/build/artifacts/contracts/router/swap-aggregator/OKXScaleHelper.sol/OKXScaleHelper.dbg.json +1 -1
- package/build/artifacts/contracts/router/swap-aggregator/ParaswapScaleHelper.sol/IAugustusV6.dbg.json +1 -1
- package/build/artifacts/contracts/router/swap-aggregator/ParaswapScaleHelper.sol/ParaswapScaleHelper.dbg.json +1 -1
- package/build/artifacts/contracts/router/swap-aggregator/ParaswapScaleHelper.sol/ParaswapScaleHelper.json +2 -2
- package/build/artifacts/contracts/router/swap-aggregator/PendleSwap.sol/IKyberScalingHelper.dbg.json +1 -1
- package/build/artifacts/contracts/router/swap-aggregator/PendleSwap.sol/IOdosRouterV2.dbg.json +1 -1
- package/build/artifacts/contracts/router/swap-aggregator/PendleSwap.sol/PendleSwap.dbg.json +1 -1
- package/build/artifacts/contracts/router/swap-aggregator/PendleSwap.sol/PendleSwap.json +2 -2
- package/contracts/LiquidityMining/CrossChainMsg/PendleMsgReceiveEndpointUpg.sol +17 -15
- package/contracts/LiquidityMining/CrossChainMsg/PendleMsgReceiverAppUpg.sol +1 -1
- package/contracts/LiquidityMining/CrossChainMsg/PendleMsgSendEndpointUpg.sol +16 -14
- package/contracts/LiquidityMining/CrossChainMsg/PendleMsgSenderAppUpg.sol +3 -2
- package/contracts/LiquidityMining/CrossChainMsg/libraries/ExcessivelySafeCall.sol +12 -9
- package/contracts/LiquidityMining/CrossChainMsg/libraries/LayerZeroHelper.sol +12 -12
- package/contracts/LiquidityMining/GaugeController/PendleGaugeControllerBaseUpg.sol +10 -8
- package/contracts/LiquidityMining/GaugeController/PendleGaugeControllerMainchainUpg.sol +12 -6
- package/contracts/LiquidityMining/GaugeController/PendleGaugeControllerSidechainUpg.sol +11 -4
- package/contracts/LiquidityMining/PendleMerkleDistributor.sol +13 -11
- package/contracts/LiquidityMining/PendleMultiTokenMerkleDistributor.sol +22 -17
- package/contracts/LiquidityMining/VotingController/PendleVotingControllerUpg.sol +28 -21
- package/contracts/LiquidityMining/VotingController/VotingControllerStorageUpg.sol +27 -31
- package/contracts/LiquidityMining/VotingEscrow/VotingEscrowPendleMainchain.sol +23 -19
- package/contracts/LiquidityMining/VotingEscrow/VotingEscrowPendleSidechain.sol +8 -7
- package/contracts/LiquidityMining/libraries/VeBalanceLib.sol +5 -6
- package/contracts/core/Market/MarketMathCore.sol +112 -78
- package/contracts/core/Market/OracleLib.sol +41 -34
- package/contracts/core/Market/PendleGauge.sol +8 -8
- package/contracts/core/Market/PendleMarketFactoryV6Upg.sol +16 -19
- package/contracts/core/Market/PendleMarketV6.sol +65 -63
- package/contracts/core/RewardManager/RewardManager.sol +8 -8
- package/contracts/core/RewardManager/RewardManagerAbstract.sol +5 -6
- package/contracts/core/StandardizedYield/PYIndex.sol +2 -2
- package/contracts/core/YieldContracts/InterestManagerYT.sol +9 -8
- package/contracts/core/YieldContracts/PendlePrincipalToken.sol +8 -4
- package/contracts/core/YieldContracts/PendleYieldContractFactoryUpg.sol +12 -15
- package/contracts/core/YieldContracts/PendleYieldToken.sol +41 -54
- package/contracts/core/erc20/PendleERC20.sol +6 -9
- package/contracts/core/libraries/ArrayLib.sol +13 -11
- package/contracts/core/libraries/BaseSplitCodeFactory.sol +29 -22
- package/contracts/core/libraries/BoringOwnableUpgradeableV2.sol +1 -2
- package/contracts/core/libraries/Errors.sol +4 -1
- package/contracts/core/libraries/ExpiryUtilsLib.sol +10 -10
- package/contracts/core/libraries/StringLib.sol +13 -13
- package/contracts/core/libraries/TokenHelper.sol +3 -3
- package/contracts/core/libraries/math/LogExpMath.sol +67 -77
- package/contracts/cross-chain/FixedPricePTAMM.sol +39 -38
- package/contracts/cross-chain/factory/hub/PendlePTOFTAdapterFactory.sol +1 -1
- package/contracts/cross-chain/oftImpl/spoke/PendleBridgedPrincipalToken.sol +1 -1
- package/contracts/deprecated/VeDistributor/PendleFeeDistributor.sol +12 -15
- package/contracts/deprecated/VeDistributor/PendleFeeDistributorV2.sol +24 -21
- package/contracts/interfaces/ILayerZeroEndpoint.sol +3 -5
- package/contracts/interfaces/IPActionCallbackV3.sol +1 -1
- package/contracts/interfaces/IPActionInfoStatic.sol +3 -1
- package/contracts/interfaces/IPActionMarketAuxStatic.sol +15 -11
- package/contracts/interfaces/IPActionMarketCoreStatic.sol +109 -58
- package/contracts/interfaces/IPActionMintRedeemStatic.sol +26 -21
- package/contracts/interfaces/IPActionMiscV3.sol +44 -24
- package/contracts/interfaces/IPActionSimple.sol +43 -24
- package/contracts/interfaces/IPActionVePendleStatic.sol +5 -4
- package/contracts/interfaces/IPAllActionTypeV3.sol +16 -14
- package/contracts/interfaces/IPAllActionV3.sol +4 -4
- package/contracts/interfaces/IPAllEventsV3.sol +21 -5
- package/contracts/interfaces/IPBridgedPrincipalToken.sol +2 -2
- package/contracts/interfaces/IPCommonSYFactory.sol +6 -3
- package/contracts/interfaces/IPExchangeRateOracleApp.sol +26 -25
- package/contracts/interfaces/IPFeeDistributorV2.sol +16 -13
- package/contracts/interfaces/IPFixedPricePTAMM.sol +34 -22
- package/contracts/interfaces/IPGovernanceProxy.sol +6 -2
- package/contracts/interfaces/IPInterestManagerYTV2.sol +3 -4
- package/contracts/interfaces/IPLimitRouter.sol +16 -16
- package/contracts/interfaces/IPMarket.sol +35 -25
- package/contracts/interfaces/IPMarketFactory.sol +16 -9
- package/contracts/interfaces/IPMerkleDistributor.sol +10 -6
- package/contracts/interfaces/IPMsgSendEndpoint.sol +12 -7
- package/contracts/interfaces/IPMultiTokenMerkleDistributor.sol +12 -6
- package/contracts/interfaces/IPPYLpOracle.sol +4 -1
- package/contracts/interfaces/IPRouterStatic.sol +3 -3
- package/contracts/interfaces/IPVotingController.sol +4 -4
- package/contracts/interfaces/IPVotingEscrowMainchain.sol +1 -1
- package/contracts/interfaces/IPYieldContractFactory.sol +5 -3
- package/contracts/interfaces/IPYieldToken.sol +11 -8
- package/contracts/interfaces/IPYieldTokenV2.sol +11 -8
- package/contracts/interfaces/IStandardizedYield.sol +17 -16
- package/contracts/limit/LimitMathCore.sol +56 -38
- package/contracts/limit/LimitRouterBase.sol +88 -66
- package/contracts/limit/PendleLimitRouter.sol +7 -11
- package/contracts/offchain-helpers/AddressProvider.sol +1 -1
- package/contracts/offchain-helpers/AutomateReady.sol +2 -2
- package/contracts/offchain-helpers/BalanceReader.sol +9 -21
- package/contracts/offchain-helpers/BaseSplitCodeFactoryContract.sol +7 -5
- package/contracts/offchain-helpers/Broadcaster.sol +3 -3
- package/contracts/offchain-helpers/BytesLib.sol +5 -3
- package/contracts/offchain-helpers/EmptyUUPS.sol +2 -2
- package/contracts/offchain-helpers/ExpiredLpPtRedeemer.sol +8 -5
- package/contracts/offchain-helpers/LegacyNFTHelper.sol +5 -1
- package/contracts/offchain-helpers/LimitBackendHelperV2.sol +12 -12
- package/contracts/offchain-helpers/Multicall2.sol +7 -9
- package/contracts/offchain-helpers/PendleExchangeRateOracle.sol +8 -4
- package/contracts/offchain-helpers/PendleGovernanceProxy.sol +10 -7
- package/contracts/offchain-helpers/PendleLPWrapper.sol +3 -12
- package/contracts/offchain-helpers/PendleLPWrapperFactory.sol +2 -2
- package/contracts/offchain-helpers/PendleMerkleDepositor.sol +64 -0
- package/contracts/offchain-helpers/PendleMulticallV1.sol +7 -7
- package/contracts/offchain-helpers/PendleMulticallV2.sol +12 -13
- package/contracts/offchain-helpers/PendleOffchainStorage.sol +1 -1
- package/contracts/offchain-helpers/PendleWstETHPriceFeed.sol +2 -4
- package/contracts/offchain-helpers/SimulateHelper.sol +6 -7
- package/contracts/offchain-helpers/deploy/PendleCommonPoolDeployHelperV2.sol +32 -13
- package/contracts/offchain-helpers/deploy/PendleCommonSYFactory.sol +11 -7
- package/contracts/offchain-helpers/deploy/PendlePoolDeployHelper.sol +35 -16
- package/contracts/offchain-helpers/deploy/PendlePoolDeployHelperV2.sol +35 -15
- package/contracts/offchain-helpers/deploy/lib/MarketDeployLib.sol +13 -12
- package/contracts/offchain-helpers/errors/SDKErrorsDirectory.sol +4 -1
- package/contracts/offchain-helpers/router-static/PendleRouterStatic.sol +1 -1
- package/contracts/offchain-helpers/router-static/base/ActionInfoStatic.sol +9 -12
- package/contracts/offchain-helpers/router-static/base/ActionMarketAuxStatic.sol +91 -60
- package/contracts/offchain-helpers/router-static/base/ActionMarketCoreStatic.sol +190 -103
- package/contracts/offchain-helpers/router-static/base/ActionMintRedeemStatic.sol +26 -26
- package/contracts/offchain-helpers/router-static/base/ActionStorageStatic.sol +3 -3
- package/contracts/offchain-helpers/router-static/base/ActionVePendleStatic.sol +10 -8
- package/contracts/offchain-helpers/router-static/base/MarketApproxLibV1.sol +40 -100
- package/contracts/oracles/CrossChainOracle/base/PendleCrossChainOracleBaseApp_Init.sol +6 -14
- package/contracts/oracles/CrossChainOracle/exchangeRate/PendleExchangeRateOracleApp.sol +47 -55
- package/contracts/oracles/CrossChainOracle/exchangeRate/PendleExchangeRateOracleV2.sol +3 -2
- package/contracts/oracles/CrossChainOracle/libraries/ExchangeRateMsgCodec.sol +12 -12
- package/contracts/oracles/PtYtLpOracle/PendleLpOracleLib.sol +20 -17
- package/contracts/oracles/PtYtLpOracle/PendlePYLpOracle.sol +19 -15
- package/contracts/oracles/PtYtLpOracle/PendlePYOracleLib.sol +6 -7
- package/contracts/oracles/PtYtLpOracle/chainlink/PendleChainlinkOracle.sol +9 -13
- package/contracts/oracles/PtYtLpOracle/chainlink/PendleChainlinkOracleFactory.sol +21 -20
- package/contracts/oracles/PtYtLpOracle/chainlink/PendleChainlinkOracleWithQuote.sol +7 -4
- package/contracts/oracles/PtYtLpOracle/samples/BoringLpSeller.sol +2 -2
- package/contracts/oracles/PtYtLpOracle/samples/BoringPYUsdChainlinkAssetOracle.sol +10 -13
- package/contracts/oracles/PtYtLpOracle/samples/BoringPYUsdChainlinkSYOracle.sol +10 -13
- package/contracts/oracles/PtYtLpOracle/samples/BoringPtSeller.sol +5 -6
- package/contracts/oracles/StatelessWrapper/PendleSparkLinearDiscountOracleFactoryWrapper.sol +1 -1
- package/contracts/oracles/internal/PendleSparkLinearDiscountOracleFactory.sol +3 -3
- package/contracts/router/ActionAddRemoveLiqV3.sol +150 -55
- package/contracts/router/ActionCallbackV3.sol +13 -20
- package/contracts/router/ActionMiscV3.sol +78 -54
- package/contracts/router/ActionSimple.sol +128 -76
- package/contracts/router/ActionSwapPTV3.sol +19 -7
- package/contracts/router/ActionSwapYTV3.sol +20 -8
- package/contracts/router/PendleRouterV4.sol +1 -1
- package/contracts/router/Reflector.sol +21 -15
- package/contracts/router/base/ActionBase.sol +105 -61
- package/contracts/router/base/ActionDelegateBase.sol +38 -39
- package/contracts/router/base/CallbackHelper.sol +19 -21
- package/contracts/router/math/ApproxStateLib.sol +28 -28
- package/contracts/router/math/MarketApproxEstimateLib.sol +13 -11
- package/contracts/router/math/MarketApproxLibOnchain.sol +24 -47
- package/contracts/router/math/MarketApproxLibV2.sol +44 -63
- package/contracts/router/swap-aggregator/OKXScaleHelper.sol +55 -191
- package/contracts/router/swap-aggregator/ParaswapScaleHelper.sol +48 -34
- package/contracts/router/swap-aggregator/PendleSwap.sol +28 -26
- package/deployments/1-core.json +2 -1
- package/deployments/1-offchain-helper.json +1 -2
- package/deployments/10-core.json +2 -1
- package/deployments/10-offchain-helper.json +1 -2
- package/deployments/146-core.json +2 -1
- package/deployments/146-offchain-helper.json +1 -2
- package/deployments/42161-core.json +2 -1
- package/deployments/42161-offchain-helper.json +1 -2
- package/deployments/5000-core.json +2 -1
- package/deployments/5000-offchain-helper.json +1 -2
- package/deployments/56-core.json +2 -1
- package/deployments/56-offchain-helper.json +1 -2
- package/deployments/80094-core.json +2 -1
- package/deployments/80094-offchain-helper.json +1 -2
- package/deployments/8453-core.json +2 -1
- package/deployments/8453-offchain-helper.json +1 -2
- package/deployments/9745-core.json +2 -1
- package/deployments/9745-offchain-helper.json +1 -2
- package/deployments/999-core.json +2 -1
- package/deployments/999-offchain-helper.json +1 -2
- package/package.json +4 -2
- package/typechain-types/IOKXDexRouter.ts +0 -99
- package/typechain-types/IPLimitRouter.ts +0 -69
- package/typechain-types/IPMarket.ts +0 -13
- package/typechain-types/PendleMerkleDepositor.ts +171 -0
- package/typechain-types/factories/ActionAddRemoveLiqV3__factory.ts +1 -1
- package/typechain-types/factories/ActionCallbackV3__factory.ts +1 -1
- package/typechain-types/factories/ActionInfoStatic__factory.ts +1 -1
- package/typechain-types/factories/ActionMarketAuxStatic__factory.ts +1 -1
- package/typechain-types/factories/ActionMarketCoreStatic__factory.ts +1 -1
- package/typechain-types/factories/ActionMintRedeemStatic__factory.ts +1 -1
- package/typechain-types/factories/ActionMiscV3__factory.ts +1 -1
- package/typechain-types/factories/ActionSimple__factory.ts +1 -1
- package/typechain-types/factories/ActionStorageStatic__factory.ts +1 -1
- package/typechain-types/factories/ActionStorageV4__factory.ts +1 -1
- package/typechain-types/factories/ActionSwapPTV3__factory.ts +1 -1
- package/typechain-types/factories/ActionSwapYTV3__factory.ts +1 -1
- package/typechain-types/factories/ActionVePendleStatic__factory.ts +1 -1
- package/typechain-types/factories/AddressProvider__factory.ts +1 -1
- package/typechain-types/factories/BalanceReader__factory.ts +1 -1
- package/typechain-types/factories/BaseSplitCodeFactoryContract__factory.ts +1 -1
- package/typechain-types/factories/BoringOwnableUpgradeableData__factory.ts +1 -1
- package/typechain-types/factories/BoringPYUsdChainlinkAssetOracle__factory.ts +1 -1
- package/typechain-types/factories/BoringPYUsdChainlinkSYOracle__factory.ts +1 -1
- package/typechain-types/factories/Broadcaster__factory.ts +1 -1
- package/typechain-types/factories/EmptyUUPS__factory.ts +1 -1
- package/typechain-types/factories/Errors__factory.ts +1 -1
- package/typechain-types/factories/ExchangeRateMsgCodec__factory.ts +1 -1
- package/typechain-types/factories/ExpiredLpPtRedeemer__factory.ts +1 -1
- package/typechain-types/factories/FixedPricePTAMM__factory.ts +1 -1
- package/typechain-types/factories/IOKXDexRouter__factory.ts +0 -171
- package/typechain-types/factories/IPLimitRouter__factory.ts +0 -42
- package/typechain-types/factories/IPMarket__factory.ts +0 -13
- package/typechain-types/factories/LegacyNFTHelper__factory.ts +1 -1
- package/typechain-types/factories/LimitBackendHelperV2__factory.ts +1 -1
- package/typechain-types/factories/Multicall2__factory.ts +1 -1
- package/typechain-types/factories/OracleLib__factory.ts +1 -1
- package/typechain-types/factories/PendleBridgedPrincipalToken__factory.ts +1 -1
- package/typechain-types/factories/PendleChainlinkOracleFactory__factory.ts +1 -1
- package/typechain-types/factories/PendleChainlinkOracleWithQuote__factory.ts +1 -1
- package/typechain-types/factories/PendleChainlinkOracle__factory.ts +1 -1
- package/typechain-types/factories/PendleCommonPoolDeployHelperV2__factory.ts +1 -1
- package/typechain-types/factories/PendleCommonSYFactory__factory.ts +1 -1
- package/typechain-types/factories/PendleERC20__factory.ts +1 -1
- package/typechain-types/factories/PendleExchangeRateOracleApp__factory.ts +1 -1
- package/typechain-types/factories/PendleExchangeRateOracleV2__factory.ts +1 -1
- package/typechain-types/factories/PendleExchangeRateOracle__factory.ts +1 -1
- package/typechain-types/factories/PendleFeeDistributorV2__factory.ts +1 -1
- package/typechain-types/factories/PendleFeeDistributor__factory.ts +1 -1
- package/typechain-types/factories/PendleGaugeControllerMainchainUpg__factory.ts +1 -1
- package/typechain-types/factories/PendleGaugeControllerSidechainUpg__factory.ts +1 -1
- package/typechain-types/factories/PendleGovernanceProxy__factory.ts +1 -1
- package/typechain-types/factories/PendleLPWrapperFactory__factory.ts +1 -1
- package/typechain-types/factories/PendleLPWrapper__factory.ts +1 -1
- package/typechain-types/factories/PendleLimitRouter__factory.ts +1 -1
- package/typechain-types/factories/PendleMarketFactoryV6Upg__factory.ts +1 -1
- package/typechain-types/factories/PendleMarketV6__factory.ts +1 -1
- package/typechain-types/factories/PendleMerkleDepositor__factory.ts +164 -0
- package/typechain-types/factories/PendleMerkleDistributor__factory.ts +1 -1
- package/typechain-types/factories/PendleMsgReceiveEndpointUpg__factory.ts +1 -1
- package/typechain-types/factories/PendleMsgSendEndpointUpg__factory.ts +1 -1
- package/typechain-types/factories/PendleMultiTokenMerkleDistributor__factory.ts +1 -1
- package/typechain-types/factories/PendleMulticallOwnerV1__factory.ts +1 -1
- package/typechain-types/factories/PendleMulticallV1__factory.ts +1 -1
- package/typechain-types/factories/PendleMulticallV2__factory.ts +1 -1
- package/typechain-types/factories/PendleOffchainStorage__factory.ts +1 -1
- package/typechain-types/factories/PendlePTOFTAdapterFactory__factory.ts +1 -1
- package/typechain-types/factories/PendlePYLpOracle__factory.ts +1 -1
- package/typechain-types/factories/PendlePoolDeployHelperV2__factory.ts +1 -1
- package/typechain-types/factories/PendlePoolDeployHelper__factory.ts +1 -1
- package/typechain-types/factories/PendlePrincipalToken__factory.ts +1 -1
- package/typechain-types/factories/PendleRouterStatic__factory.ts +1 -1
- package/typechain-types/factories/PendleRouterV4__factory.ts +1 -1
- package/typechain-types/factories/PendleSparkLinearDiscountOracleFactoryWrapper__factory.ts +1 -1
- package/typechain-types/factories/PendleSparkLinearDiscountOracleFactory__factory.ts +1 -1
- package/typechain-types/factories/PendleSwap__factory.ts +1 -1
- package/typechain-types/factories/PendleVotingControllerUpg__factory.ts +1 -1
- package/typechain-types/factories/PendleWstETHPriceFeed__factory.ts +1 -1
- package/typechain-types/factories/PendleYieldContractFactoryUpg__factory.ts +1 -1
- package/typechain-types/factories/PendleYieldToken__factory.ts +1 -1
- package/typechain-types/factories/Reflector__factory.ts +1 -1
- package/typechain-types/factories/SDKErrorsDirectory__factory.ts +1 -1
- package/typechain-types/factories/SimulateHelper__factory.ts +1 -1
- package/typechain-types/factories/VotingEscrowPendleMainchain__factory.ts +1 -1
- package/typechain-types/factories/VotingEscrowPendleSidechain__factory.ts +1 -1
- package/typechain-types/hardhat.d.ts +9 -18
- package/typechain-types/index.ts +2 -4
- package/build/artifacts/contracts/offchain-helpers/PendleFeeSetter.sol/PendleFeeSetter.dbg.json +0 -4
- package/build/artifacts/contracts/offchain-helpers/PendleFeeSetter.sol/PendleFeeSetter.json +0 -326
- package/contracts/offchain-helpers/PendleFeeSetter.sol +0 -149
|
@@ -28,11 +28,11 @@ import "../../interfaces/IPYieldContractFactory.sol";
|
|
|
28
28
|
import "@openzeppelin/contracts/token/ERC20/ERC20.sol";
|
|
29
29
|
import "@openzeppelin/contracts/utils/structs/EnumerableSet.sol";
|
|
30
30
|
|
|
31
|
-
import "../libraries/BaseSplitCodeFactory.sol";
|
|
32
|
-
import "../libraries/BoringOwnableUpgradeableV2.sol";
|
|
33
|
-
import "../libraries/Errors.sol";
|
|
34
31
|
import "../libraries/ExpiryUtilsLib.sol";
|
|
32
|
+
import "../libraries/BaseSplitCodeFactory.sol";
|
|
35
33
|
import "../libraries/MiniHelpers.sol";
|
|
34
|
+
import "../libraries/Errors.sol";
|
|
35
|
+
import "../libraries/BoringOwnableUpgradeableV2.sol";
|
|
36
36
|
import "../libraries/StringLib.sol";
|
|
37
37
|
|
|
38
38
|
import "./PendlePrincipalToken.sol";
|
|
@@ -105,19 +105,18 @@ contract PendleYieldContractFactoryUpg is BoringOwnableUpgradeableV2, IPYieldCon
|
|
|
105
105
|
* @notice Create a pair of (PT, YT) from any SY and valid expiry. Anyone can create a yield contract
|
|
106
106
|
* @dev It's intentional to make expiry an uint32 to guard against fat fingers. uint32.max is year 2106
|
|
107
107
|
*/
|
|
108
|
-
function createYieldContract(
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
}
|
|
108
|
+
function createYieldContract(
|
|
109
|
+
address SY,
|
|
110
|
+
uint32 expiry,
|
|
111
|
+
bool doCacheIndexSameBlock
|
|
112
|
+
) external returns (address PT, address YT) {
|
|
113
|
+
if (MiniHelpers.isTimeInThePast(expiry) || expiry % expiryDivisor != 0) revert Errors.YCFactoryInvalidExpiry();
|
|
115
114
|
|
|
116
115
|
if (getPT[SY][expiry] != address(0)) revert Errors.YCFactoryYieldContractExisted();
|
|
117
116
|
|
|
118
117
|
IStandardizedYield _SY = IStandardizedYield(SY);
|
|
119
118
|
|
|
120
|
-
(
|
|
119
|
+
(, , uint8 assetDecimals) = _SY.assetInfo();
|
|
121
120
|
|
|
122
121
|
string memory syCoreName = _SY.name().stripPrefix(SY_NAME_PREF);
|
|
123
122
|
string memory syCoreSymbol = _SY.symbol().stripPrefix(SY_SYMBOL_PREF);
|
|
@@ -173,18 +172,16 @@ contract PendleYieldContractFactoryUpg is BoringOwnableUpgradeableV2, IPYieldCon
|
|
|
173
172
|
}
|
|
174
173
|
|
|
175
174
|
function setInterestFeeRate(uint128 newInterestFeeRate) public onlyOwner {
|
|
176
|
-
if (newInterestFeeRate > maxInterestFeeRate)
|
|
175
|
+
if (newInterestFeeRate > maxInterestFeeRate)
|
|
177
176
|
revert Errors.YCFactoryInterestFeeRateTooHigh(newInterestFeeRate, maxInterestFeeRate);
|
|
178
|
-
}
|
|
179
177
|
|
|
180
178
|
interestFeeRate = newInterestFeeRate;
|
|
181
179
|
emit SetInterestFeeRate(newInterestFeeRate);
|
|
182
180
|
}
|
|
183
181
|
|
|
184
182
|
function setRewardFeeRate(uint128 newRewardFeeRate) public onlyOwner {
|
|
185
|
-
if (newRewardFeeRate > maxRewardFeeRate)
|
|
183
|
+
if (newRewardFeeRate > maxRewardFeeRate)
|
|
186
184
|
revert Errors.YCFactoryRewardFeeRateTooHigh(newRewardFeeRate, maxRewardFeeRate);
|
|
187
|
-
}
|
|
188
185
|
|
|
189
186
|
rewardFeeRate = newRewardFeeRate;
|
|
190
187
|
emit SetRewardFeeRate(newRewardFeeRate);
|
|
@@ -3,26 +3,26 @@ pragma solidity ^0.8.17;
|
|
|
3
3
|
|
|
4
4
|
import "@openzeppelin/contracts/token/ERC20/utils/SafeERC20.sol";
|
|
5
5
|
|
|
6
|
-
import "../../interfaces/IPPrincipalToken.sol";
|
|
7
|
-
import "../../interfaces/IPYieldToken.sol";
|
|
8
6
|
import "../../interfaces/IStandardizedYield.sol";
|
|
7
|
+
import "../../interfaces/IPYieldToken.sol";
|
|
8
|
+
import "../../interfaces/IPPrincipalToken.sol";
|
|
9
9
|
|
|
10
|
+
import "../libraries/math/PMath.sol";
|
|
11
|
+
import "../libraries/ArrayLib.sol";
|
|
10
12
|
import "../../interfaces/IPYieldContractFactory.sol";
|
|
11
13
|
import "../StandardizedYield/SYUtils.sol";
|
|
12
|
-
import "../libraries/ArrayLib.sol";
|
|
13
14
|
import "../libraries/Errors.sol";
|
|
14
15
|
import "../libraries/MiniHelpers.sol";
|
|
15
|
-
import "../libraries/math/PMath.sol";
|
|
16
16
|
|
|
17
17
|
import "../RewardManager/RewardManagerAbstract.sol";
|
|
18
18
|
import "../erc20/PendleERC20.sol";
|
|
19
19
|
import "./InterestManagerYT.sol";
|
|
20
20
|
|
|
21
21
|
/**
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
22
|
+
Invariance to maintain:
|
|
23
|
+
- address(0) & address(this) should never have any rewards & activeBalance accounting done. This is
|
|
24
|
+
guaranteed by address(0) & address(this) check in each updateForTwo function
|
|
25
|
+
*/
|
|
26
26
|
contract PendleYieldToken is IPYieldToken, PendleERC20, RewardManagerAbstract, InterestManagerYT {
|
|
27
27
|
using PMath for uint256;
|
|
28
28
|
using SafeERC20 for IERC20;
|
|
@@ -87,13 +87,10 @@ contract PendleYieldToken is IPYieldToken, PendleERC20, RewardManagerAbstract, I
|
|
|
87
87
|
* @notice Tokenize SY into PT + YT of equal qty. Every unit of asset of SY will create 1 PT + 1 YT
|
|
88
88
|
* @dev SY must be transferred to this contract prior to calling
|
|
89
89
|
*/
|
|
90
|
-
function mintPY(
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
updateData
|
|
95
|
-
returns (uint256 amountPYOut)
|
|
96
|
-
{
|
|
90
|
+
function mintPY(
|
|
91
|
+
address receiverPT,
|
|
92
|
+
address receiverYT
|
|
93
|
+
) external nonReentrant notExpired updateData returns (uint256 amountPYOut) {
|
|
97
94
|
address[] memory receiverPTs = new address[](1);
|
|
98
95
|
address[] memory receiverYTs = new address[](1);
|
|
99
96
|
uint256[] memory amountSyToMints = new uint256[](1);
|
|
@@ -116,9 +113,8 @@ contract PendleYieldToken is IPYieldToken, PendleERC20, RewardManagerAbstract, I
|
|
|
116
113
|
if (receiverYTs.length != length || amountSyToMints.length != length) revert Errors.ArrayLengthMismatch();
|
|
117
114
|
|
|
118
115
|
uint256 totalSyToMint = amountSyToMints.sum();
|
|
119
|
-
if (totalSyToMint > _getFloatingSyAmount())
|
|
116
|
+
if (totalSyToMint > _getFloatingSyAmount())
|
|
120
117
|
revert Errors.YieldContractInsufficientSy(totalSyToMint, _getFloatingSyAmount());
|
|
121
|
-
}
|
|
122
118
|
|
|
123
119
|
amountPYOuts = _mintPY(receiverPTs, receiverYTs, amountSyToMints);
|
|
124
120
|
}
|
|
@@ -144,12 +140,10 @@ contract PendleYieldToken is IPYieldToken, PendleERC20, RewardManagerAbstract, I
|
|
|
144
140
|
* @dev PT/YT must be transferred to this contract prior to calling
|
|
145
141
|
* @dev fails if unable to redeem the total PY amount in `amountPYToRedeems`
|
|
146
142
|
*/
|
|
147
|
-
function redeemPYMulti(
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
returns (uint256[] memory amountSyOuts)
|
|
152
|
-
{
|
|
143
|
+
function redeemPYMulti(
|
|
144
|
+
address[] calldata receivers,
|
|
145
|
+
uint256[] calldata amountPYToRedeems
|
|
146
|
+
) external nonReentrant updateData returns (uint256[] memory amountSyOuts) {
|
|
153
147
|
if (receivers.length != amountPYToRedeems.length) revert Errors.ArrayLengthMismatch();
|
|
154
148
|
if (receivers.length == 0) revert Errors.ArrayEmpty();
|
|
155
149
|
amountSyOuts = _redeemPY(receivers, amountPYToRedeems);
|
|
@@ -165,12 +159,11 @@ contract PendleYieldToken is IPYieldToken, PendleERC20, RewardManagerAbstract, I
|
|
|
165
159
|
* time, unless users redeem their dueInterest or redeemPY. Due to this, it is required to
|
|
166
160
|
* update users' accruedReward STRICTLY BEFORE transferring out their interest.
|
|
167
161
|
*/
|
|
168
|
-
function redeemDueInterestAndRewards(
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
{
|
|
162
|
+
function redeemDueInterestAndRewards(
|
|
163
|
+
address user,
|
|
164
|
+
bool redeemInterest,
|
|
165
|
+
bool redeemRewards
|
|
166
|
+
) external nonReentrant updateData returns (uint256 interestOut, uint256[] memory rewardsOut) {
|
|
174
167
|
if (!redeemInterest && !redeemRewards) revert Errors.YCNothingToRedeem();
|
|
175
168
|
|
|
176
169
|
// if redeemRewards == true, this line must be here for obvious reason
|
|
@@ -281,9 +274,7 @@ contract PendleYieldToken is IPYieldToken, PendleERC20, RewardManagerAbstract, I
|
|
|
281
274
|
uint256[] memory userRewardOwed
|
|
282
275
|
)
|
|
283
276
|
{
|
|
284
|
-
if (postExpiry.firstPYIndex == 0)
|
|
285
|
-
revert Errors.YCPostExpiryDataNotSet();
|
|
286
|
-
}
|
|
277
|
+
if (postExpiry.firstPYIndex == 0) revert Errors.YCPostExpiryDataNotSet();
|
|
287
278
|
|
|
288
279
|
firstPYIndex = postExpiry.firstPYIndex;
|
|
289
280
|
totalSyInterestForTreasury = postExpiry.totalSyInterestForTreasury;
|
|
@@ -298,10 +289,11 @@ contract PendleYieldToken is IPYieldToken, PendleERC20, RewardManagerAbstract, I
|
|
|
298
289
|
}
|
|
299
290
|
}
|
|
300
291
|
|
|
301
|
-
function _mintPY(
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
292
|
+
function _mintPY(
|
|
293
|
+
address[] memory receiverPTs,
|
|
294
|
+
address[] memory receiverYTs,
|
|
295
|
+
uint256[] memory amountSyToMints
|
|
296
|
+
) internal returns (uint256[] memory amountPYOuts) {
|
|
305
297
|
amountPYOuts = new uint256[](amountSyToMints.length);
|
|
306
298
|
|
|
307
299
|
uint256 index = _pyIndexCurrent();
|
|
@@ -320,10 +312,10 @@ contract PendleYieldToken is IPYieldToken, PendleERC20, RewardManagerAbstract, I
|
|
|
320
312
|
return MiniHelpers.isCurrentlyExpired(expiry);
|
|
321
313
|
}
|
|
322
314
|
|
|
323
|
-
function _redeemPY(
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
{
|
|
315
|
+
function _redeemPY(
|
|
316
|
+
address[] memory receivers,
|
|
317
|
+
uint256[] memory amountPYToRedeems
|
|
318
|
+
) internal returns (uint256[] memory amountSyOuts) {
|
|
327
319
|
uint256 totalAmountPYToRedeem = amountPYToRedeems.sum();
|
|
328
320
|
IPPrincipalToken(PT).burnByYT(address(this), totalAmountPYToRedeem);
|
|
329
321
|
if (!isExpired()) _burn(address(this), totalAmountPYToRedeem);
|
|
@@ -350,11 +342,10 @@ contract PendleYieldToken is IPYieldToken, PendleERC20, RewardManagerAbstract, I
|
|
|
350
342
|
return SYUtils.syToAsset(indexCurrent, amountSy);
|
|
351
343
|
}
|
|
352
344
|
|
|
353
|
-
function _calcSyRedeemableFromPY(
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
{
|
|
345
|
+
function _calcSyRedeemableFromPY(
|
|
346
|
+
uint256 amountPY,
|
|
347
|
+
uint256 indexCurrent
|
|
348
|
+
) internal view returns (uint256 syToUser, uint256 syInterestPostExpiry) {
|
|
358
349
|
syToUser = SYUtils.assetToSy(indexCurrent, amountPY);
|
|
359
350
|
if (isExpired()) {
|
|
360
351
|
uint256 totalSyRedeemable = SYUtils.assetToSy(postExpiry.firstPYIndex, amountPY);
|
|
@@ -424,12 +415,10 @@ contract PendleYieldToken is IPYieldToken, PendleERC20, RewardManagerAbstract, I
|
|
|
424
415
|
return IStandardizedYield(SY).getRewardTokens();
|
|
425
416
|
}
|
|
426
417
|
|
|
427
|
-
function _doTransferOutRewards(
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
returns (uint256[] memory rewardAmounts)
|
|
432
|
-
{
|
|
418
|
+
function _doTransferOutRewards(
|
|
419
|
+
address user,
|
|
420
|
+
address receiver
|
|
421
|
+
) internal virtual override returns (uint256[] memory rewardAmounts) {
|
|
433
422
|
address[] memory tokens = getRewardTokens();
|
|
434
423
|
|
|
435
424
|
if (isExpired()) {
|
|
@@ -493,9 +482,7 @@ contract PendleYieldToken is IPYieldToken, PendleERC20, RewardManagerAbstract, I
|
|
|
493
482
|
tokens = getRewardTokens();
|
|
494
483
|
if (isExpired()) {
|
|
495
484
|
indexes = new uint256[](tokens.length);
|
|
496
|
-
for (uint256 i = 0; i < tokens.length; i++)
|
|
497
|
-
indexes[i] = postExpiry.firstRewardIndex[tokens[i]];
|
|
498
|
-
}
|
|
485
|
+
for (uint256 i = 0; i < tokens.length; i++) indexes[i] = postExpiry.firstRewardIndex[tokens[i]];
|
|
499
486
|
} else {
|
|
500
487
|
indexes = IStandardizedYield(SY).rewardIndexesCurrent();
|
|
501
488
|
}
|
|
@@ -160,13 +160,11 @@ contract PendleERC20 is Context, IERC20, IERC20Metadata {
|
|
|
160
160
|
* - the caller must have allowance for ``from``'s tokens of at least
|
|
161
161
|
* `amount`.
|
|
162
162
|
*/
|
|
163
|
-
function transferFrom(
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
returns (bool)
|
|
169
|
-
{
|
|
163
|
+
function transferFrom(
|
|
164
|
+
address from,
|
|
165
|
+
address to,
|
|
166
|
+
uint256 amount
|
|
167
|
+
) external virtual override nonReentrant returns (bool) {
|
|
170
168
|
address spender = _msgSender();
|
|
171
169
|
_spendAllowance(from, spender, amount);
|
|
172
170
|
_transfer(from, to, amount);
|
|
@@ -206,8 +204,7 @@ contract PendleERC20 is Context, IERC20, IERC20Metadata {
|
|
|
206
204
|
_afterTokenTransfer(from, to, amount);
|
|
207
205
|
}
|
|
208
206
|
|
|
209
|
-
/**
|
|
210
|
-
* @dev Creates `amount` tokens and assigns them to `account`, increasing
|
|
207
|
+
/** @dev Creates `amount` tokens and assigns them to `account`, increasing
|
|
211
208
|
* the total supply.
|
|
212
209
|
*
|
|
213
210
|
* Emits a {Transfer} event with `from` set to the zero address.
|
|
@@ -4,7 +4,7 @@ pragma solidity ^0.8.0;
|
|
|
4
4
|
library ArrayLib {
|
|
5
5
|
function sum(uint256[] memory input) internal pure returns (uint256) {
|
|
6
6
|
uint256 value = 0;
|
|
7
|
-
for (uint256 i = 0; i < input.length;) {
|
|
7
|
+
for (uint256 i = 0; i < input.length; ) {
|
|
8
8
|
value += input[i];
|
|
9
9
|
unchecked {
|
|
10
10
|
i++;
|
|
@@ -16,7 +16,7 @@ library ArrayLib {
|
|
|
16
16
|
/// @notice return index of the element if found, else return uint256.max
|
|
17
17
|
function find(address[] memory array, address element) internal pure returns (uint256 index) {
|
|
18
18
|
uint256 length = array.length;
|
|
19
|
-
for (uint256 i = 0; i < length;) {
|
|
19
|
+
for (uint256 i = 0; i < length; ) {
|
|
20
20
|
if (array[i] == element) return i;
|
|
21
21
|
unchecked {
|
|
22
22
|
i++;
|
|
@@ -28,7 +28,7 @@ library ArrayLib {
|
|
|
28
28
|
function append(address[] memory inp, address element) internal pure returns (address[] memory out) {
|
|
29
29
|
uint256 length = inp.length;
|
|
30
30
|
out = new address[](length + 1);
|
|
31
|
-
for (uint256 i = 0; i < length;) {
|
|
31
|
+
for (uint256 i = 0; i < length; ) {
|
|
32
32
|
out[i] = inp[i];
|
|
33
33
|
unchecked {
|
|
34
34
|
i++;
|
|
@@ -41,7 +41,7 @@ library ArrayLib {
|
|
|
41
41
|
uint256 length = inp.length;
|
|
42
42
|
out = new address[](length + 1);
|
|
43
43
|
out[0] = element;
|
|
44
|
-
for (uint256 i = 1; i <= length;) {
|
|
44
|
+
for (uint256 i = 1; i <= length; ) {
|
|
45
45
|
out[i] = inp[i - 1];
|
|
46
46
|
unchecked {
|
|
47
47
|
i++;
|
|
@@ -82,7 +82,7 @@ library ArrayLib {
|
|
|
82
82
|
// various version of contains
|
|
83
83
|
function contains(address[] memory array, address element) internal pure returns (bool) {
|
|
84
84
|
uint256 length = array.length;
|
|
85
|
-
for (uint256 i = 0; i < length;) {
|
|
85
|
+
for (uint256 i = 0; i < length; ) {
|
|
86
86
|
if (array[i] == element) return true;
|
|
87
87
|
unchecked {
|
|
88
88
|
i++;
|
|
@@ -93,7 +93,7 @@ library ArrayLib {
|
|
|
93
93
|
|
|
94
94
|
function contains(bytes4[] memory array, bytes4 element) internal pure returns (bool) {
|
|
95
95
|
uint256 length = array.length;
|
|
96
|
-
for (uint256 i = 0; i < length;) {
|
|
96
|
+
for (uint256 i = 0; i < length; ) {
|
|
97
97
|
if (array[i] == element) return true;
|
|
98
98
|
unchecked {
|
|
99
99
|
i++;
|
|
@@ -128,11 +128,13 @@ library ArrayLib {
|
|
|
128
128
|
res[3] = d;
|
|
129
129
|
}
|
|
130
130
|
|
|
131
|
-
function create(
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
131
|
+
function create(
|
|
132
|
+
address a,
|
|
133
|
+
address b,
|
|
134
|
+
address c,
|
|
135
|
+
address d,
|
|
136
|
+
address e
|
|
137
|
+
) internal pure returns (address[] memory res) {
|
|
136
138
|
res = new address[](5);
|
|
137
139
|
res[0] = a;
|
|
138
140
|
res[1] = b;
|
|
@@ -87,7 +87,9 @@ library CodeDeployer {
|
|
|
87
87
|
}
|
|
88
88
|
|
|
89
89
|
library BaseSplitCodeFactory {
|
|
90
|
-
function setCreationCode(
|
|
90
|
+
function setCreationCode(
|
|
91
|
+
bytes memory creationCode
|
|
92
|
+
)
|
|
91
93
|
internal
|
|
92
94
|
returns (
|
|
93
95
|
address creationCodeContractA,
|
|
@@ -102,8 +104,8 @@ library BaseSplitCodeFactory {
|
|
|
102
104
|
|
|
103
105
|
// We are going to deploy two contracts: one with approximately the first half of `creationCode`'s contents
|
|
104
106
|
// (A), and another with the remaining half (B).
|
|
105
|
-
// We store the lengths in both immutable and stack variables, since immutable variables cannot be read
|
|
106
|
-
//
|
|
107
|
+
// We store the lengths in both immutable and stack variables, since immutable variables cannot be read during
|
|
108
|
+
// construction.
|
|
107
109
|
creationCodeSizeA = creationCodeSize / 2;
|
|
108
110
|
|
|
109
111
|
creationCodeSizeB = creationCodeSize - creationCodeSizeA;
|
|
@@ -114,8 +116,8 @@ library BaseSplitCodeFactory {
|
|
|
114
116
|
|
|
115
117
|
// Memory: [ code length ] [ A.data ] [ B.data ]
|
|
116
118
|
|
|
117
|
-
// Creating A's array is simple: we simply replace `creationCode`'s length with A's length. We'll later
|
|
118
|
-
//
|
|
119
|
+
// Creating A's array is simple: we simply replace `creationCode`'s length with A's length. We'll later restore
|
|
120
|
+
// the original length.
|
|
119
121
|
|
|
120
122
|
bytes memory creationCodeA;
|
|
121
123
|
assembly {
|
|
@@ -128,9 +130,8 @@ library BaseSplitCodeFactory {
|
|
|
128
130
|
|
|
129
131
|
creationCodeContractA = CodeDeployer.deploy(creationCodeA);
|
|
130
132
|
|
|
131
|
-
// Creating B's array is a bit more involved: since we cannot move B's contents, we are going to create a
|
|
132
|
-
//
|
|
133
|
-
// this last
|
|
133
|
+
// Creating B's array is a bit more involved: since we cannot move B's contents, we are going to create a 'new'
|
|
134
|
+
// memory array starting at A's last 32 bytes, which will be replaced with B's length. We'll back-up this last
|
|
134
135
|
// byte to later restore it.
|
|
135
136
|
|
|
136
137
|
bytes memory creationCodeB;
|
|
@@ -149,8 +150,7 @@ library BaseSplitCodeFactory {
|
|
|
149
150
|
|
|
150
151
|
creationCodeContractB = CodeDeployer.deploy(creationCodeB);
|
|
151
152
|
|
|
152
|
-
// We now restore the original contents of `creationCode` by writing back the original length and A's last
|
|
153
|
-
// byte.
|
|
153
|
+
// We now restore the original contents of `creationCode` by writing back the original length and A's last byte.
|
|
154
154
|
assembly {
|
|
155
155
|
mstore(creationCodeA, creationCodeSize)
|
|
156
156
|
mstore(creationCodeB, lastByteA)
|
|
@@ -167,9 +167,14 @@ library BaseSplitCodeFactory {
|
|
|
167
167
|
address creationCodeContractB,
|
|
168
168
|
uint256 creationCodeSizeB
|
|
169
169
|
) internal view returns (bytes memory) {
|
|
170
|
-
return
|
|
171
|
-
|
|
172
|
-
|
|
170
|
+
return
|
|
171
|
+
_getCreationCodeWithArgs(
|
|
172
|
+
"",
|
|
173
|
+
creationCodeContractA,
|
|
174
|
+
creationCodeSizeA,
|
|
175
|
+
creationCodeContractB,
|
|
176
|
+
creationCodeSizeB
|
|
177
|
+
);
|
|
173
178
|
}
|
|
174
179
|
|
|
175
180
|
/**
|
|
@@ -183,11 +188,10 @@ library BaseSplitCodeFactory {
|
|
|
183
188
|
uint256 creationCodeSizeB
|
|
184
189
|
) private view returns (bytes memory code) {
|
|
185
190
|
unchecked {
|
|
186
|
-
// This function exists because `abi.encode()` cannot be instructed to place its result at a specific
|
|
187
|
-
//
|
|
188
|
-
// code,
|
|
189
|
-
//
|
|
190
|
-
// code, which would be prohibitively expensive.
|
|
191
|
+
// This function exists because `abi.encode()` cannot be instructed to place its result at a specific address.
|
|
192
|
+
// We need for the ABI-encoded constructor arguments to be located immediately after the creation code, but
|
|
193
|
+
// cannot rely on `abi.encodePacked()` to perform concatenation as that would involve copying the creation code,
|
|
194
|
+
// which would be prohibitively expensive.
|
|
191
195
|
// Instead, we compute the creation code in a pre-allocated array that is large enough to hold *both* the
|
|
192
196
|
// creation code and the constructor arguments, and then copy the ABI-encoded arguments (which should not be
|
|
193
197
|
// overly long) right after the end of the creation code.
|
|
@@ -200,9 +204,8 @@ library BaseSplitCodeFactory {
|
|
|
200
204
|
uint256 codeSize = creationCodeSize + constructorArgsSize;
|
|
201
205
|
|
|
202
206
|
assembly {
|
|
203
|
-
// First, we allocate memory for `code` by retrieving the free memory pointer and then moving it ahead
|
|
204
|
-
//
|
|
205
|
-
// length.
|
|
207
|
+
// First, we allocate memory for `code` by retrieving the free memory pointer and then moving it ahead of
|
|
208
|
+
// `code` by the size of the creation code plus constructor arguments, and 32 bytes for the array length.
|
|
206
209
|
code := mload(0x40)
|
|
207
210
|
mstore(0x40, add(code, add(codeSize, 32)))
|
|
208
211
|
|
|
@@ -243,7 +246,11 @@ library BaseSplitCodeFactory {
|
|
|
243
246
|
) internal returns (address) {
|
|
244
247
|
unchecked {
|
|
245
248
|
bytes memory creationCode = _getCreationCodeWithArgs(
|
|
246
|
-
constructorArgs,
|
|
249
|
+
constructorArgs,
|
|
250
|
+
creationCodeContractA,
|
|
251
|
+
creationCodeSizeA,
|
|
252
|
+
creationCodeContractB,
|
|
253
|
+
creationCodeSizeB
|
|
247
254
|
);
|
|
248
255
|
return Create2.deploy(amount, salt, creationCode);
|
|
249
256
|
}
|
|
@@ -19,8 +19,7 @@ abstract contract BoringOwnableUpgradeableV2 is BoringOwnableUpgradeableData, In
|
|
|
19
19
|
/// Can only be invoked by the current `owner`.
|
|
20
20
|
/// @param newOwner Address of the new owner.
|
|
21
21
|
/// @param direct True if `newOwner` should be set immediately. False if `newOwner` needs to use `claimOwnership`.
|
|
22
|
-
/// @param renounce Allows the `newOwner` to be `address(0)` if `direct` and `renounce` is True. Has no effect
|
|
23
|
-
/// otherwise.
|
|
22
|
+
/// @param renounce Allows the `newOwner` to be `address(0)` if `direct` and `renounce` is True. Has no effect otherwise.
|
|
24
23
|
function transferOwnership(address newOwner, bool direct, bool renounce) public onlyOwner {
|
|
25
24
|
if (direct) {
|
|
26
25
|
// Checks
|
|
@@ -19,7 +19,10 @@ library Errors {
|
|
|
19
19
|
error ApproxFail();
|
|
20
20
|
error ApproxParamsInvalid(uint256 guessMin, uint256 guessMax, uint256 eps);
|
|
21
21
|
error ApproxBinarySearchInputInvalid(
|
|
22
|
-
uint256 approxGuessMin,
|
|
22
|
+
uint256 approxGuessMin,
|
|
23
|
+
uint256 approxGuessMax,
|
|
24
|
+
uint256 minGuessMin,
|
|
25
|
+
uint256 maxGuessMax
|
|
23
26
|
);
|
|
24
27
|
|
|
25
28
|
// MARKET + MARKET MATH CORE
|
|
@@ -8,9 +8,9 @@ library ExpiryUtils {
|
|
|
8
8
|
uint8 day;
|
|
9
9
|
}
|
|
10
10
|
|
|
11
|
-
uint256 private constant DAY_IN_SECONDS =
|
|
12
|
-
uint256 private constant YEAR_IN_SECONDS =
|
|
13
|
-
uint256 private constant LEAP_YEAR_IN_SECONDS =
|
|
11
|
+
uint256 private constant DAY_IN_SECONDS = 86400;
|
|
12
|
+
uint256 private constant YEAR_IN_SECONDS = 31536000;
|
|
13
|
+
uint256 private constant LEAP_YEAR_IN_SECONDS = 31622400;
|
|
14
14
|
uint16 private constant ORIGIN_YEAR = 1970;
|
|
15
15
|
|
|
16
16
|
/**
|
|
@@ -21,13 +21,13 @@ library ExpiryUtils {
|
|
|
21
21
|
* @param _expiry The expiry in epoch time.
|
|
22
22
|
* @param _delimiter Can be any delimiter, but usually "-" or " ".
|
|
23
23
|
* @return result Returns the concatenated string.
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
{
|
|
24
|
+
**/
|
|
25
|
+
function concat(
|
|
26
|
+
string memory _bt,
|
|
27
|
+
string memory _yt,
|
|
28
|
+
uint256 _expiry,
|
|
29
|
+
string memory _delimiter
|
|
30
|
+
) internal pure returns (string memory result) {
|
|
31
31
|
result = string(abi.encodePacked(_bt, _delimiter, _yt, _delimiter, toRFC2822String(_expiry)));
|
|
32
32
|
}
|
|
33
33
|
|
|
@@ -471,11 +471,12 @@ library StringLib {
|
|
|
471
471
|
|
|
472
472
|
// Returns the memory address of the first byte of the first occurrence of
|
|
473
473
|
// `needle` in `self`, or the first byte after `self` if not found.
|
|
474
|
-
function findPtr(
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
|
|
474
|
+
function findPtr(
|
|
475
|
+
uint256 selflen,
|
|
476
|
+
uint256 selfptr,
|
|
477
|
+
uint256 needlelen,
|
|
478
|
+
uint256 needleptr
|
|
479
|
+
) private pure returns (uint256) {
|
|
479
480
|
uint256 ptr = selfptr;
|
|
480
481
|
uint256 idx;
|
|
481
482
|
|
|
@@ -527,11 +528,12 @@ library StringLib {
|
|
|
527
528
|
|
|
528
529
|
// Returns the memory address of the first byte after the last occurrence of
|
|
529
530
|
// `needle` in `self`, or the address of `self` if not found.
|
|
530
|
-
function rfindPtr(
|
|
531
|
-
|
|
532
|
-
|
|
533
|
-
|
|
534
|
-
|
|
531
|
+
function rfindPtr(
|
|
532
|
+
uint256 selflen,
|
|
533
|
+
uint256 selfptr,
|
|
534
|
+
uint256 needlelen,
|
|
535
|
+
uint256 needleptr
|
|
536
|
+
) private pure returns (uint256) {
|
|
535
537
|
uint256 ptr;
|
|
536
538
|
|
|
537
539
|
if (needlelen <= selflen) {
|
|
@@ -736,9 +738,7 @@ library StringLib {
|
|
|
736
738
|
if (parts.length == 0) return "";
|
|
737
739
|
|
|
738
740
|
uint256 length = self._len * (parts.length - 1);
|
|
739
|
-
for (uint256 i = 0; i < parts.length; i++)
|
|
740
|
-
length += parts[i]._len;
|
|
741
|
-
}
|
|
741
|
+
for (uint256 i = 0; i < parts.length; i++) length += parts[i]._len;
|
|
742
742
|
|
|
743
743
|
string memory ret = new string(length);
|
|
744
744
|
uint256 retptr;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
// SPDX-License-Identifier: GPL-3.0-or-later
|
|
2
2
|
pragma solidity ^0.8.0;
|
|
3
3
|
|
|
4
|
-
import "../../interfaces/IWETH.sol";
|
|
5
4
|
import "@openzeppelin/contracts/token/ERC20/extensions/IERC20Metadata.sol";
|
|
6
5
|
import "@openzeppelin/contracts/token/ERC20/utils/SafeERC20.sol";
|
|
6
|
+
import "../../interfaces/IWETH.sol";
|
|
7
7
|
|
|
8
8
|
abstract contract TokenHelper {
|
|
9
9
|
using SafeERC20 for IERC20;
|
|
@@ -23,7 +23,7 @@ abstract contract TokenHelper {
|
|
|
23
23
|
function _transferOut(address token, address to, uint256 amount) internal {
|
|
24
24
|
if (amount == 0) return;
|
|
25
25
|
if (token == NATIVE) {
|
|
26
|
-
(bool success,) = to.call{value: amount}("");
|
|
26
|
+
(bool success, ) = to.call{value: amount}("");
|
|
27
27
|
require(success, "eth send failed");
|
|
28
28
|
} else {
|
|
29
29
|
IERC20(token).safeTransfer(to, amount);
|
|
@@ -33,7 +33,7 @@ abstract contract TokenHelper {
|
|
|
33
33
|
function _transferOut(address[] memory tokens, address to, uint256[] memory amounts) internal {
|
|
34
34
|
uint256 numTokens = tokens.length;
|
|
35
35
|
require(numTokens == amounts.length, "length mismatch");
|
|
36
|
-
for (uint256 i = 0; i < numTokens;) {
|
|
36
|
+
for (uint256 i = 0; i < numTokens; ) {
|
|
37
37
|
_transferOut(tokens[i], to, amounts[i]);
|
|
38
38
|
unchecked {
|
|
39
39
|
i++;
|