-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: Add Hybrid (Curve + UniV3) exchange for Zappers
- Loading branch information
Showing
12 changed files
with
509 additions
and
100 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
32 changes: 32 additions & 0 deletions
32
contracts/src/Zappers/Modules/Exchanges/Curve/ICurveStableswapNGFactory.sol
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
// SPDX-License-Identifier: MIT | ||
|
||
pragma solidity ^0.8.0; | ||
|
||
import "./ICurveStableswapNGPool.sol"; | ||
|
||
interface ICurveStableswapNGFactory { | ||
/* | ||
function deploy_plain_pool( | ||
string memory name, | ||
string memory symbol, | ||
address[2] memory coins, | ||
uint256 A, | ||
uint256 fee, | ||
uint256 asset_type, | ||
uint256 implementation_id | ||
) external returns (ICurvePool); | ||
*/ | ||
function deploy_plain_pool( | ||
string memory name, | ||
string memory symbol, | ||
address[] memory coins, | ||
uint256 A, | ||
uint256 fee, | ||
uint256 offpeg_fee_multiplier, | ||
uint256 ma_exp_time, | ||
uint256 implementation_id, | ||
uint8[] memory asset_types, | ||
bytes4[] memory method_ids, | ||
address[] memory oracles | ||
) external returns (ICurveStableswapNGPool); | ||
} |
9 changes: 9 additions & 0 deletions
9
contracts/src/Zappers/Modules/Exchanges/Curve/ICurveStableswapNGPool.sol
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
// SPDX-License-Identifier: MIT | ||
|
||
pragma solidity ^0.8.0; | ||
|
||
interface ICurveStableswapNGPool { | ||
function add_liquidity(uint256[] memory amounts, uint256 min_mint_amount) external returns (uint256); | ||
function exchange(int128 i, int128 j, uint256 dx, uint256 min_dy) external returns (uint256 output); | ||
function get_dx(int128 i, int128 j, uint256 dy) external view returns (uint256 dx); | ||
} |
Oops, something went wrong.